From 6ed6803d0dd8cd3fc93208d614c3558b962a654e Mon Sep 17 00:00:00 2001 From: Jouke Witteveen Date: Sun, 15 Apr 2012 11:51:43 +0200 Subject: Restore support for kernel command line It is once again possible to use NET= at the kernel command line when using net-profiles. --- scripts/netcfg-menu | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'scripts') diff --git a/scripts/netcfg-menu b/scripts/netcfg-menu index a62838a..b6aa402 100755 --- a/scripts/netcfg-menu +++ b/scripts/netcfg-menu @@ -48,14 +48,13 @@ ret=$? case $ret in 1) ;; # Cancel - do nothing 255) # timeout - use default - profile_up "$DEFAULT" # JP: use profile_up and catch $? - ret=$? - (( ret == 0 )) && echo "$DEFAULT" > "$STATE_DIR/menu" - ;; + PROFILE=$DEFAULT;;& 0) # User selection - profile_up "$(< "$ANSWER")" + PROFILE=$(< "$ANSWER");;& + 255|0) + profile_up "$PROFILE" ret=$? - (( ret == 0 )) && mv "$ANSWER" "$STATE_DIR/menu" + (( ret == 0 )) && echo "$PROFILE" > "$STATE_DIR/menu" ;; *) # Shouldnt happen exit_err "Abnormal ret code from dialog: $ret" -- cgit v1.2.3-24-g4f1b