apps/speed.c:2541: error: NULL_DEREFERENCE
  pointer `fds` last assigned on line 2534 could be null and is dereferenced at line 2541, column 4.
Showing all 9 steps of the trace


apps/speed.c:2527:1: start of procedure do_multi()
2525.       }
2526.   
2527. > static int do_multi(int multi)
2528.   	{
2529.   	int n;

apps/speed.c:2532:2: 
2530.   	int fd[2];
2531.   	int *fds;
2532. > 	static char sep[]=":";
2533.   
2534.   	fds=malloc(multi*sizeof *fds);

apps/speed.c:2534:2: 
2532.   	static char sep[]=":";
2533.   
2534. > 	fds=malloc(multi*sizeof *fds);
2535.   	for(n=0 ; n < multi ; ++n)
2536.   		{

apps/speed.c:2535:6: 
2533.   
2534.   	fds=malloc(multi*sizeof *fds);
2535. > 	for(n=0 ; n < multi ; ++n)
2536.   		{
2537.   		pipe(fd);

apps/speed.c:2535:12: Loop condition is true. Entering loop body
2533.   
2534.   	fds=malloc(multi*sizeof *fds);
2535.   	for(n=0 ; n < multi ; ++n)
                   ^
2536.   		{
2537.   		pipe(fd);

apps/speed.c:2537:3: 
2535.   	for(n=0 ; n < multi ; ++n)
2536.   		{
2537. > 		pipe(fd);
2538.   		if(fork())
2539.   			{

apps/speed.c:2538:6: Taking true branch
2536.   		{
2537.   		pipe(fd);
2538.   		if(fork())
             ^
2539.   			{
2540.   			close(fd[1]);

apps/speed.c:2540:4: 
2538.   		if(fork())
2539.   			{
2540. > 			close(fd[1]);
2541.   			fds[n]=fd[0];
2542.   			}

apps/speed.c:2541:4: 
2539.   			{
2540.   			close(fd[1]);
2541. > 			fds[n]=fd[0];
2542.   			}
2543.   		else
