1 |
< |
/* Copyright (c) 1997 Regents of the University of California */ |
1 |
> |
/* Copyright (c) 1998 Silicon Graphics, Inc. */ |
2 |
|
|
3 |
|
#ifndef lint |
4 |
< |
static char SCCSid[] = "$SunId$ LBL"; |
4 |
> |
static char SCCSid[] = "$SunId$ SGI"; |
5 |
|
#endif |
6 |
|
|
7 |
|
/* |
186 |
|
|
187 |
|
if (tmTop == NULL) |
188 |
|
returnErr(TM_E_TMINVAL); |
189 |
< |
if (ls == NULL | scan == NULL | len <= 0) |
189 |
> |
if (ls == NULL | scan == NULL | len < 0) |
190 |
|
returnErr(TM_E_ILLEGAL); |
191 |
|
for (i = len; i--; ) { |
192 |
|
if (tmNeedMatrix(tmTop)) /* get monitor RGB */ |
257 |
|
int oldorig, oldlen, horig, hlen; |
258 |
|
register int i, j; |
259 |
|
|
260 |
– |
if (len <= 0) |
261 |
– |
returnErr(TM_E_ILLEGAL); |
260 |
|
if (tmTop == NULL) |
261 |
|
returnErr(TM_E_TMINVAL); |
262 |
+ |
if (len < 0) |
263 |
+ |
returnErr(TM_E_ILLEGAL); |
264 |
+ |
if (len == 0) |
265 |
+ |
returnOK; |
266 |
|
/* first, grow limits */ |
267 |
|
if (tmTop->histo == NULL) { |
268 |
|
for (i = len; i-- && ls[i] < MINBRT; ) |
450 |
|
|
451 |
|
if (tmTop == NULL || tmTop->lumap == NULL) |
452 |
|
returnErr(TM_E_TMINVAL); |
453 |
< |
if (ps == NULL | ls == NULL | len <= 0) |
453 |
> |
if (ps == NULL | ls == NULL | len < 0) |
454 |
|
returnErr(TM_E_ILLEGAL); |
455 |
|
while (len--) { |
456 |
|
if ((li = *ls++) < tmTop->mbrmin) |