From: Michael Adam Date: Tue, 4 Sep 2012 13:17:37 +0000 (+0200) Subject: s3: in sys_popen(), improve call to pipe and report error to debug X-Git-Tag: samba-4.0.0rc1~245 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=d43c411fb19707f1b57177e9a3300573018cc849;p=thirdparty%2Fsamba.git s3: in sys_popen(), improve call to pipe and report error to debug --- diff --git a/source3/lib/system.c b/source3/lib/system.c index ce55e83d583..30f2ac6d008 100644 --- a/source3/lib/system.c +++ b/source3/lib/system.c @@ -1166,8 +1166,12 @@ int sys_popen(const char *command) return -1; } - if (pipe(pipe_fds) < 0) + ret = pipe(pipe_fds); + if (ret < 0) { + DEBUG(0, ("sys_popen: error opening pipe: %s\n", + strerror(errno))); return -1; + } parent_end = pipe_fds[0]; child_end = pipe_fds[1];