Changeset 15530


Ignore:
Timestamp:
2009-05-01T00:59:18+02:00 (9 years ago)
Author:
nbd
Message:

rcS: wait for init scripts to complete before initiating the shutdown (patch from #5032)

Location:
trunk/package/base-files/files/etc/init.d
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/package/base-files/files/etc/init.d/boot

    r15245 r15530  
    5353        killall -q hotplug2 
    5454        [ -x /sbin/hotplug2 ] && /sbin/hotplug2 --override --persistent \ 
    55                         --max-children 1 --no-coldplug & 
     55                        --max-children 1 --no-coldplug >/dev/null 2>&1 & 
    5656 
    5757        # the coldplugging of network interfaces needs to happen later, so we do it manually here 
  • trunk/package/base-files/files/etc/init.d/rcS

    r15323 r15530  
    11#!/bin/sh 
    22# Copyright (C) 2006 OpenWrt.org 
     3 
     4run_scripts() { 
     5        for i in /etc/rc.d/$1*; do 
     6                [ -x $i ] && $i $2 2>&1 
     7        done | $LOGGER 
     8} 
    39 
    410LOGGER="cat" 
    511[ -x /usr/bin/logger ] && LOGGER="logger -s -p 6 -t sysinit" 
    612 
    7 { 
    8         for i in /etc/rc.d/$1*; do 
    9                 [ -x $i ] && $i $2 2>&1 
    10         done  
    11 } | $LOGGER & 
     13if [ "$1" = "S" ]; then 
     14        run_scripts "$1" "$2" & 
     15else 
     16        run_scripts "$1" "$2" 
     17fi 
Note: See TracChangeset for help on using the changeset viewer.