** Add current char to buffer (if not out of space) and read next one */
| 401 | ** Add current char to buffer (if not out of space) and read next one |
| 402 | */ |
| 403 | static int nextc (RN *rn) { |
| 404 | if (rn->n >= L_MAXLENNUM) { /* buffer overflow? */ |
| 405 | rn->buff[0] = '\0'; /* invalidate result */ |
| 406 | return 0; /* fail */ |
| 407 | } |
| 408 | else { |
| 409 | rn->buff[rn->n++] = rn->c; /* save current char */ |
| 410 | rn->c = l_getc(rn->f); /* read next one */ |
| 411 | return 1; |
| 412 | } |
| 413 | } |
| 414 | |
| 415 | |
| 416 | /* |
no outgoing calls
no test coverage detected