![](https://seccdn.libravatar.org/avatar/1221572c74a1df78a3aa2625b979eb21.jpg?s=120&d=mm&r=g)
Author: gs Date: Tue Jul 5 13:01:33 2011 New Revision: 64751 URL: http://svn.opensuse.org/viewcvs/yast?rev=64751&view=rev Log: add revert cmd, get default values Modified: trunk/fcoe-client/src/FcoeClient.ycp Modified: trunk/fcoe-client/src/FcoeClient.ycp URL: http://svn.opensuse.org/viewcvs/yast/trunk/fcoe-client/src/FcoeClient.ycp?re... ============================================================================== --- trunk/fcoe-client/src/FcoeClient.ycp (original) +++ trunk/fcoe-client/src/FcoeClient.ycp Tue Jul 5 13:01:33 2011 @@ -369,9 +369,19 @@ boolean ret = SCR::Write( .target.string, file_name, def_values ); if ( ret == true ) { - status_map = add( status_map, "FCOE_ENABLE", "yes"); - status_map = add( status_map, "DCB_REQUIRED", "yes"); + list <string> lines = splitstring( def_values, "\n" ); + foreach( string line, (list<string>)lines, { + if ( regexpmatch( line, "^FCOE_ENABLE" ) ) + { + status_map = add( status_map, "FCOE_ENABLE", deletechars( substring(line, 12), "\"") ); + } + if ( regexpmatch( line, "^DCB_REQUIRED" ) ) + { + status_map = add( status_map, "DCB_REQUIRED", deletechars( substring( line, 13 ),"\"") ); + } + }); status_map = add( status_map, "Filename", file_name ); + AddRevertCommand( sformat( "rm %1", file_name ) ); } else { @@ -390,7 +400,6 @@ } list <string> lines = splitstring( content, "\n" ); - foreach( string line, (list<string>)lines, { if ( regexpmatch( line, "^FCOE_ENABLE" ) ) { -- To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org For additional commands, e-mail: yast-commit+help@opensuse.org