Date: Fri, 3 Apr 2020 14:03:59 +0000 (UTC) From: Mark Johnston <markj@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r359596 - head/usr.bin/xargs Message-ID: <202004031403.033E3xaE004782@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: markj Date: Fri Apr 3 14:03:58 2020 New Revision: 359596 URL: https://svnweb.freebsd.org/changeset/base/359596 Log: xargs: Fix exit status expression when a child process fails to exec. PR: 244327 Submitted by: thomas.duffy.99@alumni.brown.edu MFC after: 1 week Modified: head/usr.bin/xargs/xargs.c Modified: head/usr.bin/xargs/xargs.c ============================================================================== --- head/usr.bin/xargs/xargs.c Fri Apr 3 13:57:41 2020 (r359595) +++ head/usr.bin/xargs/xargs.c Fri Apr 3 14:03:58 2020 (r359596) @@ -650,7 +650,7 @@ waitchildren(const char *name, int waitall) if (childerr != 0 && cause_exit == 0) { errno = childerr; waitall = 1; - cause_exit = ENOENT ? 127 : 126; + cause_exit = errno == ENOENT ? 127 : 126; warn("%s", name); } else if (WIFSIGNALED(status)) { waitall = cause_exit = 1;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202004031403.033E3xaE004782>