summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source3/lib/smbrun.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source3/lib/smbrun.c b/source3/lib/smbrun.c
index 0642c30a75..5b05c64bf0 100644
--- a/source3/lib/smbrun.c
+++ b/source3/lib/smbrun.c
@@ -58,7 +58,7 @@ static BOOL setup_stdout_file(char *outfile,BOOL shared)
if (fd == -1) return False;
if (fd != 1) {
- if (dup2(fd,1) != 0) {
+ if (dup2(fd,1) != 1) {
DEBUG(2,("Failed to create stdout file descriptor\n"));
close(fd);
return False;