Bug Summary

File:src/stdio/pclose.c
Location:line 12, column 2
Description:Undefined or garbage value returned to caller

Annotated Source Code

1#include "stdio_impl.h"
2#include <errno(*__errno_location()).h>
3#include <unistd.h>
4
5int pclose(FILE *f)
6{
7 int status, r;
1
'status' declared without an initial value
8 pid_t pid = f->pipe_pid;
9 fclose(f);
10 while ((r=__syscall(SYS_wait4, pid, &status, 0, 0)__syscall4(61,((long) (pid)),((long) (&status)),((long) (
0)),((long) (0)))
) == -EINTR4);
2
Loop condition is false. Execution continues on line 11
11 if (r<0) return __syscall_ret(r);
3
Assuming 'r' is >= 0
4
Taking false branch
12 return status;
5
Undefined or garbage value returned to caller
13}