[yast-commit] r52670 - in /trunk/support: package/yast2-support.changes src/dialogs.ycp
Author: jsrain Date: Wed Oct 29 14:53:08 2008 New Revision: 52670 URL: http://svn.opensuse.org/viewcvs/yast?rev=52670&view=rev Log: issue a warning before starting browser as root Modified: trunk/support/package/yast2-support.changes trunk/support/src/dialogs.ycp Modified: trunk/support/package/yast2-support.changes URL: http://svn.opensuse.org/viewcvs/yast/trunk/support/package/yast2-support.changes?rev=52670&r1=52669&r2=52670&view=diff ============================================================================== --- trunk/support/package/yast2-support.changes (original) +++ trunk/support/package/yast2-support.changes Wed Oct 29 14:53:08 2008 @@ -1,4 +1,9 @@ ------------------------------------------------------------------- +Wed Oct 29 14:52:50 CET 2008 - jsrain@suse.cz + +- issue a warning before starting browser as root + +------------------------------------------------------------------- Wed Oct 29 14:07:23 CET 2008 - mzugec@suse.de - fixed layout Modified: trunk/support/src/dialogs.ycp URL: http://svn.opensuse.org/viewcvs/yast/trunk/support/src/dialogs.ycp?rev=52670&r1=52669&r2=52670&view=diff ============================================================================== --- trunk/support/src/dialogs.ycp (original) +++ trunk/support/src/dialogs.ycp Wed Oct 29 14:53:08 2008 @@ -118,8 +118,17 @@ if (Support::browser==nil) Popup::Error(_("Couldn't find any installed browser.")); else{ string url="http://www.novell.com/center/eservice"; - y2milestone("Executing browser %1 with URL %2", Support::browser, url); - SCR::Execute(.target.bash, sformat("su $(env|grep LOGNAME|cut -d'=' -f2-) -c \"%1 %2\"", Support::browser, url)); + if (0 == SCR::Execute (.target.bash, "env|grep LOGNAME|cut -d'=' -f2- | grep root")) + { + if (Popup::ContinueCancel (sformat (_("YaST will run a web browser as superuser. Consider +running it as a non-provileged user and entering URL +%1. +Start web browser?"), url))) + { + y2milestone("Executing browser %1 with URL %2", Support::browser, url); + SCR::Execute(.target.bash, sformat("su $(env|grep LOGNAME|cut -d'=' -f2-) -c \"%1 %2\"", Support::browser, url)); + } + } } } } -- To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org For additional commands, e-mail: yast-commit+help@opensuse.org
participants (1)
-
jsrain@svn.opensuse.org