111 |
int ndelim = -1; /* zero-based / one-based problem */ |
int ndelim = -1; /* zero-based / one-based problem */ |
112 |
int nfields_printed = 0; |
int nfields_printed = 0; |
113 |
char *field = NULL; |
char *field = NULL; |
114 |
const char delimiter[2] = { delim, 0 }; |
char delimiter[2]; |
115 |
|
|
116 |
|
delimiter[0] = delim; |
117 |
|
delimiter[1] = 0; |
118 |
|
|
119 |
/* does this line contain any delimiters? */ |
/* does this line contain any delimiters? */ |
120 |
if (strchr(line, delim) == NULL) { |
if (strchr(line, delim) == NULL) { |
264 |
/* now that the lists are parsed, we need to sort them to make life |
/* now that the lists are parsed, we need to sort them to make life |
265 |
* easier on us when it comes time to print the chars / fields / lines |
* easier on us when it comes time to print the chars / fields / lines |
266 |
*/ |
*/ |
267 |
qsort(cut_lists, nlists, sizeof(struct cut_list), cmpfunc); |
qsort(cut_lists, nlists, sizeof(cut_lists[0]), cmpfunc); |
268 |
} |
} |
269 |
|
|
270 |
{ |
{ |