]> git.ipfire.org Git - pakfire.git/commitdiff
tests: command: Always return zero after the pipe is finished
authorMichael Tremer <michael.tremer@ipfire.org>
Sat, 22 Mar 2025 14:19:46 +0000 (14:19 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Sat, 22 Mar 2025 14:19:46 +0000 (14:19 +0000)
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
tests/stub/command.c

index 053661b56a13856ebf2676716717b00959057257..01c17113846e47d812d15fd8608343fec74378b2 100644 (file)
@@ -355,7 +355,7 @@ static int _pipe(int argc, char* argv[]) {
 
                // Break if we are done reading
                if (c == EOF)
-                       return errno;
+                       break;
 
                // Write the character to stdout
                r = fputc(c, stdout);
@@ -368,6 +368,8 @@ static int _pipe(int argc, char* argv[]) {
                                break;
                }
        }
+
+       return 0;
 }
 
 /*