Author: fehr Date: Wed Jan 13 14:55:23 2010 New Revision: 60350 URL: http://svn.opensuse.org/viewcvs/yast?rev=60350&view=rev Log: set fs to detected fs when format is set to false to prevent invalid fstab options (bnc #457100) 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=60350&r1=60349&r2=60350&view=diff ============================================================================== --- trunk/storage/package/yast2-storage.changes (original) +++ trunk/storage/package/yast2-storage.changes Wed Jan 13 14:55:23 2010 @@ -1,4 +1,10 @@ ------------------------------------------------------------------- +Wed Jan 13 14:54:47 CET 2010 - fehr@suse.de + +- set fs to detected fs when format is set to false to prevent + invalid fstab options (bnc #457100) + +------------------------------------------------------------------- Tue Jan 12 16:51:38 CET 2010 - fehr@suse.de - do not forget user modified format options when FormatMount dialog Modified: trunk/storage/storage/src/modules/Storage.ycp URL: http://svn.opensuse.org/viewcvs/yast/trunk/storage/storage/src/modules/Storage.ycp?rev=60350&r1=60349&r2=60350&view=diff ============================================================================== --- trunk/storage/storage/src/modules/Storage.ycp (original) +++ trunk/storage/storage/src/modules/Storage.ycp Wed Jan 13 14:55:23 2010 @@ -584,11 +584,11 @@ } else if( search( device, "/dev/md" )==0 && size(ls)==2 ) { - integer pos = find(device, "p"); - if (pos == -1) - dlen = 7; - else + integer pos = search(device, "p"); + if (pos > 0) dlen = pos; + else + dlen = 7; } else if( search( device, "/dev/loop" )==0 ) { @@ -1218,9 +1218,11 @@ p["name"] = LibStorage::VolumeInfo::swig_name_get(vinfo); integer t = LibStorage::VolumeInfo::swig_fs_get(vinfo); symbol fs = toSymbol( FileSystems::conv_fs, t ); - p["detected_fs"] = fs; - if( fs != `unknown ) + if( fs!=`unknown ) p["used_fs"] = fs; + t = LibStorage::VolumeInfo::swig_detected_fs_get(vinfo); + fs = toSymbol( FileSystems::conv_fs, t ); + p["detected_fs"] = fs; boolean tbool = LibStorage::VolumeInfo::swig_format_get(vinfo); if( tbool ) p["format"] = true; @@ -1257,7 +1259,7 @@ { p["mkfs_opt"] = tmp; p["fs_options"] = - convertStringToFsOptionMap( tmp, p["detected_fs"]:`unknown, `mkfs ); + convertStringToFsOptionMap( tmp, p["used_fs"]:`unknown, `mkfs ); } else { @@ -1269,7 +1271,7 @@ { p["tunefs_opt"] = tmp; p["fs_options"] = union(p["fs_options"]:$[], - convertStringToFsOptionMap( tmp, p["detected_fs"]:`unknown, `tunefs )); + convertStringToFsOptionMap( tmp, p["used_fs"]:`unknown, `tunefs )); } tmp = LibStorage::VolumeInfo::swig_dtxt_get(vinfo); if( size(tmp)>0 ) @@ -3613,9 +3615,11 @@ (!lvm && DetectHomeFs(ret))) { ret["format"] = false; - ret["used_fs"] = ret["detected_fs"]:`unknown; - if (isempty(fstab_opts)) + if( ret["used_fs"]:`unknown!=ret["detected_fs"]:`unknown ) + { + ret["used_fs"] = ret["detected_fs"]:`unknown; fstab_opts = FileSystems::DefaultFstabOptions(ret); + } } } if( ret["format"]:false && !ret["create"]:false && -- To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org For additional commands, e-mail: yast-commit+help@opensuse.org