9 |
|
|
10 |
|
#include "standard.h" |
11 |
|
|
12 |
+ |
#include <string.h> |
13 |
+ |
|
14 |
|
#include "color.h" |
15 |
|
|
16 |
|
#define RSCA 1.13 /* square-radius multiplier: sqrt(4/PI) */ |
101 |
|
ringsum = (float *)malloc((orad+1)*sizeof(float)); |
102 |
|
ringwt = (short *)malloc((orad+1)*sizeof(short)); |
103 |
|
warr = (float *)malloc(obarsize*obarsize*sizeof(float)); |
104 |
< |
if (ringsum == NULL | ringwt == 0 | warr == NULL) |
104 |
> |
if ((ringsum == NULL) | (ringwt == 0) | (warr == NULL)) |
105 |
|
goto memerr; |
106 |
|
return; |
107 |
|
memerr: |
192 |
|
register int c, x; |
193 |
|
register float *gscan; |
194 |
|
/* compute ring sums */ |
195 |
< |
bzero((char *)ringsum, (orad+1)*sizeof(float)); |
196 |
< |
bzero((char *)ringwt, (orad+1)*sizeof(short)); |
195 |
> |
memset((char *)ringsum, '\0', (orad+1)*sizeof(float)); |
196 |
> |
memset((char *)ringwt, '\0', (orad+1)*sizeof(short)); |
197 |
|
for (r = -orad; r <= orad; r++) { |
198 |
|
if (rcent+r < 0) continue; |
199 |
|
if (rcent+r >= nrows) break; |