Magellan Linux

Diff of /trunk/initscripts/busybox/rc/network

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1227 by niro, Thu Feb 17 22:24:59 2011 UTC revision 1275 by niro, Fri May 6 22:09:19 2011 UTC
# Line 115  checkconfig() Line 115  checkconfig()
115   DHCP_PROG="/sbin/udhcpc"   DHCP_PROG="/sbin/udhcpc"
116   fi   fi
117   [[ -z ${DHCP_START} ]] && DHCP_START="-T10"   [[ -z ${DHCP_START} ]] && DHCP_START="-T10"
118   [[ -z ${DHCP_STOP} ]] && DHCP_STOP="-k"   [[ -z ${DHCP_STOP} ]] && DHCP_STOP=""
119   ;;   ;;
120    
121   esac   esac
# Line 131  onboot_interface_list() Line 131  onboot_interface_list()
131   # get list of all devices   # get list of all devices
132   for file in $@   for file in $@
133   do   do
134     iface="$(basename ${file} | sed s/net.//)"
135    
136     # exclude backup files and exclude net.routes and net.sample too
137     case "${iface}" in
138     *~) continue ;;
139     routes) continue ;;
140     sample) continue ;;
141     esac
142    
143   if [[ $(read_value ONBOOT ${file}) = yes ]]   if [[ $(read_value ONBOOT ${file}) = yes ]]
144   then   then
145   iface="$(basename ${file} | sed s/net.//)"   devices="${devices} ${iface}"
  # exclude backup files and exclude net.routes too  
  case "${iface}" in  
  *~) ;;  
  */net.routes) ;;  
  *) devices="${devices} $(basename ${file} | sed s/net.//)" ;;  
  esac  
146   fi   fi
147   done   done
148    
# Line 484  networking_start() Line 487  networking_start()
487   ${CURS_UP}   ${CURS_UP}
488   ${SET_WWCOL}   ${SET_WWCOL}
489   rc_echo "[DHCP]"   rc_echo "[DHCP]"
490   loadproc "${DHCP_PROG}" "${DHCP_START}" "${iface}"   loadproc ${DHCP_PROG} ${DHCP_START} "${iface}"
491   ;;   ;;
492   static|STATIC)   static|STATIC)
493   ${CURS_UP}   ${CURS_UP}
# Line 583  networking_stop() Line 586  networking_stop()
586   fi   fi
587    
588   # shutdown dhcp-daemon   # shutdown dhcp-daemon
589   if [[ ${NETWORKING} = dhcp ]] && [[ -n $(pidof ${DHCP_PROG}) ]]   if [[ ${NETWORKING} = dhcp ]] && [[ -n $(pidof $(basename ${DHCP_PROG})) ]]
590   then   then
591   rc_print "Stopping the dhcp-daemon ..."   rc_print "Stopping the dhcp-daemon ..."
592   ${CURS_UP}   ${CURS_UP}
593   ${SET_WWCOL}   ${SET_WWCOL}
594   rc_echo "[$(basename ${DHCP_PROG})]"   rc_echo "[$(basename ${DHCP_PROG})]"
595   ${DHCP_PROG} ${DHCP_STOP} "${iface}"   if [[ -z ${DHCP_STOP} ]]
596   evaluate_retval   then
597     killproc ${DHCP_PROG}
598     evaluate_retval
599     else
600     ${DHCP_PROG} ${DHCP_STOP} "${iface}"
601     evaluate_retval
602     fi
603   fi   fi
604    
605   # shutdown wpa_supplicant daemon   # shutdown wpa_supplicant daemon

Legend:
Removed from v.1227  
changed lines
  Added in v.1275