Create a new d-pointer when copying Device class.
Fixes a crash in Calamares
This commit is contained in:
parent
7e8bab3b4e
commit
1021e375b4
|
@ -55,6 +55,7 @@ Device::Device(std::shared_ptr<DevicePrivate> d_ptr,
|
|||
Device::Device(const Device& other)
|
||||
: QObject()
|
||||
{
|
||||
d = std::make_shared<DevicePrivate>();
|
||||
d->m_Name = other.d->m_Name;
|
||||
d->m_DeviceNode = other.d->m_DeviceNode;
|
||||
d->m_LogicalSectorSize = other.d->m_LogicalSectorSize;
|
||||
|
|
Loading…
Reference in New Issue