tools/rgb2ycbcr.c:152: error: Null Dereference
  pointer `v` last assigned on line 149 could be null and is dereferenced at line 152, column 3.

tools/rgb2ycbcr.c:146:1: start of procedure setupLuma()
144. int	Yzero;
145. 
146. static float*
     ^
147. setupLuma(float c)
148. {

tools/rgb2ycbcr.c:149:2: 
147. setupLuma(float c)
148. {
149. 	float *v = (float *)_TIFFmalloc(256 * sizeof (float));
      ^
150. 	int i;
151. 	for (i = 0; i < 256; i++)

libtiff/tif_unix.c:277:1: start of procedure _TIFFmalloc()
  275. #endif
  276. 
  277. void*
       ^
  278. _TIFFmalloc(tmsize_t s)
  279. {

libtiff/tif_unix.c:280:13: Taking false branch
  278. _TIFFmalloc(tmsize_t s)
  279. {
  280.         if (s == 0)
                   ^
  281.                 return ((void *) NULL);
  282. 

libtiff/tif_unix.c:283:2: 
  281.                 return ((void *) NULL);
  282. 
  283. 	return (malloc((size_t) s));
        ^
  284. }
  285. 

libtiff/tif_unix.c:284:1: return from a call to _TIFFmalloc
  282. 
  283. 	return (malloc((size_t) s));
  284. }
       ^
  285. 
  286. void

tools/rgb2ycbcr.c:151:7: 
149. 	float *v = (float *)_TIFFmalloc(256 * sizeof (float));
150. 	int i;
151. 	for (i = 0; i < 256; i++)
           ^
152. 		v[i] = c * i;
153. 	return (v);

tools/rgb2ycbcr.c:151:14: Loop condition is true. Entering loop body
149. 	float *v = (float *)_TIFFmalloc(256 * sizeof (float));
150. 	int i;
151. 	for (i = 0; i < 256; i++)
                  ^
152. 		v[i] = c * i;
153. 	return (v);

tools/rgb2ycbcr.c:152:3: 
150. 	int i;
151. 	for (i = 0; i < 256; i++)
152. 		v[i] = c * i;
       ^
153. 	return (v);
154. }
