[Mageia-dev] Freeze push: webmin

David Walser luigiwalser at yahoo.com
Thu Feb 7 21:01:17 CET 2013


David Walser <luigiwalser at ...> writes:
> Well, my build log on Mageia 2 shows it running find-debuginfo.sh as well, it
> just doesn't fail there.  It's not clear why.  I ran it manually with bash -x
> (after exporting the RPM_BUILD_ROOT variable) and it ends with:
> + read nlinks inum f
> + exit
> 
> and the exit status is 1.
> 
> In find-debuginfo.sh, it's actually a string of commands being piped to
> while read nlinks inum f; do
> 
> and I ran that string of commands (find | file | sed | xargs | ) manually,
> and once it gets past the sed part of the pipeline, the output is empty.
> 
> So read should exit with a non-zero exit status, and the contents of the while
> loop shouldn't run.  However, this shouldn't cause the whole script to exit 1.
> 
> That while loop does end with done || exit, but that shouldn't get hit.
> 
> This gives a zero exit status:
> echo -n '' | while read foo; do true; done

Hmm, running the commands in the pipeline by hand, I am now noticing that the
file command part of it leaves an exit status of 1.  With this in the script:
set -o pipefail

That would make the whole pipeline exit with 1, so there's the problem.

The last file that file runs on is /etc/rc.d/init.d/webmin, which it reports
as POSIX shell script, ASCII text executable.

I don't know why it's exiting with a non-zero exit status.

find strikes again!



More information about the Mageia-dev mailing list