Lines Matching defs:fp
243 FILE *fp = fopen(fname, "r");
244 if (!fp) {
249 if(!fgets(toybuf, sizeof(toybuf), fp)) return; //skip header.
251 while (fgets(toybuf, sizeof(toybuf), fp)) {
266 fclose(fp);
274 FILE *fp = fopen(fname, "r");
275 if (!fp) {
280 if(!fgets(toybuf, sizeof(toybuf), fp)) return; //skip header.
282 while (fgets(toybuf, sizeof(toybuf), fp)) {
299 fclose(fp);
307 FILE *fp = fopen((char *)fname, "r");
308 if (!fp) {
313 if(!fgets(toybuf, sizeof(toybuf), fp)) return; //skip header.
315 while (fgets(toybuf, sizeof(toybuf), fp)) {
368 fclose(fp);
524 FILE *fp = xfopen("/proc/net/route", "r");
526 if(!fgets(toybuf, sizeof(toybuf), fp)) return; //skip header.
532 while (fgets(toybuf, sizeof(toybuf), fp)) {
539 if ((nitems < 0) && feof(fp)) break;
578 fclose(fp);