check if there actually is a partition in the partwidget before accessing it
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1113935
This commit is contained in:
parent
72775ba8a0
commit
f2e216cb43
|
@ -173,7 +173,7 @@ void PartitionManagerWidget::setSelectedPartition(const Partition* p)
|
|||
|
||||
Partition* PartitionManagerWidget::selectedPartition()
|
||||
{
|
||||
if (selectedDevice() == NULL || selectedDevice()->partitionTable() == NULL || partTableWidget().activeWidget() == NULL)
|
||||
if (selectedDevice() == NULL || selectedDevice()->partitionTable() == NULL || partTableWidget().activeWidget() == NULL || partTableWidget().activeWidget()->partition() == NULL)
|
||||
return NULL;
|
||||
|
||||
// The active partition we get from the part table widget is const; we need non-const.
|
||||
|
|
Loading…
Reference in New Issue