[yast-commit] r60727 - in /trunk/storage: package/yast2-storage.changes storage/src/modules/Storage.ycp
Author: aschnell Date: Mon Feb 8 14:21:48 2010 New Revision: 60727 URL: http://svn.opensuse.org/viewcvs/yast?rev=60727&view=rev Log: - do not allow deletion of partitions on DASD when other partitions of that DASD are in use (bnc #577468) Modified: trunk/storage/package/yast2-storage.changes trunk/storage/storage/src/modules/Storage.ycp Modified: trunk/storage/package/yast2-storage.changes URL: http://svn.opensuse.org/viewcvs/yast/trunk/storage/package/yast2-storage.changes?rev=60727&r1=60726&r2=60727&view=diff ============================================================================== --- trunk/storage/package/yast2-storage.changes (original) +++ trunk/storage/package/yast2-storage.changes Mon Feb 8 14:21:48 2010 @@ -1,4 +1,10 @@ ------------------------------------------------------------------- +Mon Feb 08 14:03:47 CET 2010 - aschnell@suse.de + +- do not allow deletion of partitions on DASD when other partitions + of that DASD are in use (bnc #577468) + +------------------------------------------------------------------- Mon Feb 08 11:25:39 CET 2010 - aschnell@suse.de - allow deletion of certain partitioned RAIDs (bnc #577468) Modified: trunk/storage/storage/src/modules/Storage.ycp URL: http://svn.opensuse.org/viewcvs/yast/trunk/storage/storage/src/modules/Storage.ycp?rev=60727&r1=60726&r2=60727&view=diff ============================================================================== --- trunk/storage/storage/src/modules/Storage.ycp (original) +++ trunk/storage/storage/src/modules/Storage.ycp Mon Feb 8 14:21:48 2010 @@ -3767,6 +3767,21 @@ Popup::Message( txt ); } } + + if (ret && substring(disk["device"]:"", 0, 9) == "/dev/dasd") + { + if (find(map partition, disk["partitions"]:[], { + return partition["device"]:"" != p["device"]:"" && + !isempty(partition["used_by"]:[]); }) != nil) + { + txt = sformat(_(" +Partition %1 cannot be removed since other partitions on the +disk %2 are in used."), p["device"]:"", disk["device"]:""); + Popup::Message(txt); + ret = false; + }; + } + y2milestone( "CanDelete dev:%1 verbose:%2 ret:%3", p["device"]:"", verbose, ret ); return( ret ); -- To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org For additional commands, e-mail: yast-commit+help@opensuse.org
participants (1)
-
aschnell@svn.opensuse.org