mirror of
https://github.com/parchlinux/calamares.git
synced 2025-06-27 01:15:38 -04:00
Don't leak memory when winnowing disk devices
- Improve logging a little - Don't leak Device*, but delete the raw pointer when erasing - Document that DeviceInfo takes ownership and doesn't leak
This commit is contained in:
parent
e26d5ab206
commit
0e96621b94
2 changed files with 18 additions and 7 deletions
|
@ -122,6 +122,7 @@ PartitionCoreModule::doInit()
|
|||
cDebug() << "node\tcapacity\tname\tprettyName";
|
||||
for ( auto device : devices )
|
||||
{
|
||||
// Gives ownership of the Device* to the DeviceInfo object
|
||||
auto deviceInfo = new DeviceInfo( device );
|
||||
m_deviceInfos << deviceInfo;
|
||||
cDebug() << device->deviceNode() << device->capacity() << device->name() << device->prettyName();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue