[Pm-utils] various errors in pm/functions
Peter Jones
pjones at redhat.com
Wed Oct 11 15:48:16 PDT 2006
On Wed, 2006-10-11 at 21:40 +0200, Stefan Seyfried wrote:
> On Tue, Oct 10, 2006 at 12:13:58PM -0400, Peter Jones wrote:
>
> > Actually, I'm committing this, instead:
> >
> > @@ -62,13 +62,19 @@ run_hooks()
> > [ -f /var/run/pm-suspend ] && . /var/run/pm-suspend
> > rm -f /var/run/pm-suspend
> >
> > - files="/etc/pm/hooks/*"
> > + files="/etc/pm/hooks/*[^~]"
> > if [ "$2" = "reverse" ]; then
> > - files=$(echo $files | awk '{ for (i=NF; i>=1; i--) if ($i !~ /~$/ { print $i } }')
> > + filea=($files)
> > + filen=${#filea[*]}
> > + while [ "$filen" -gt 0 ]; do
> > + file="${filea[$filen]}"
> > + [ -x $file ] && $file $1
> > + done
>
> we never get out of this loop.
Eek, sorry ;)
--
Peter
More information about the Pm-utils
mailing list