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


apps/speed.c:2498:1: start of procedure do_multi()
2496.   
2497.   #ifdef HAVE_FORK
2498. > static int do_multi(int multi)
2499.   	{
2500.   	int n;

apps/speed.c:2503:2: 
2501.   	int fd[2];
2502.   	int *fds;
2503. > 	static char sep[]=":";
2504.   
2505.   	fds=malloc(multi*sizeof *fds);

apps/speed.c:2505:2: 
2503.   	static char sep[]=":";
2504.   
2505. > 	fds=malloc(multi*sizeof *fds);
2506.   	for(n=0 ; n < multi ; ++n)
2507.   		{

apps/speed.c:2506:6: 
2504.   
2505.   	fds=malloc(multi*sizeof *fds);
2506. > 	for(n=0 ; n < multi ; ++n)
2507.   		{
2508.   		pipe(fd);

apps/speed.c:2506:12: Loop condition is true. Entering loop body
2504.   
2505.   	fds=malloc(multi*sizeof *fds);
2506.   	for(n=0 ; n < multi ; ++n)
                   ^
2507.   		{
2508.   		pipe(fd);

apps/speed.c:2508:3: 
2506.   	for(n=0 ; n < multi ; ++n)
2507.   		{
2508. > 		pipe(fd);
2509.   		if(fork())
2510.   			{

apps/speed.c:2509:6: Taking true branch
2507.   		{
2508.   		pipe(fd);
2509.   		if(fork())
             ^
2510.   			{
2511.   			close(fd[1]);

apps/speed.c:2511:4: 
2509.   		if(fork())
2510.   			{
2511. > 			close(fd[1]);
2512.   			fds[n]=fd[0];
2513.   			}

apps/speed.c:2512:4: 
2510.   			{
2511.   			close(fd[1]);
2512. > 			fds[n]=fd[0];
2513.   			}
2514.   		else
