Lines Matching refs:fh
1507 add2fs_from_file(filesystem *fs, uint32 this_nod, FILE * fh, uint32 fs_timestamp, struct stats *stats)
1517 fstat(fileno(fh), &st);
1520 while(getline(&line, &len, fh) >= 0)
1659 FILE *fh;
1763 fh = xfopen(dent->d_name, "rb");
1764 nod = mkfile_fs(fs, this_nod, name, mode, st.st_size, fh, uid, gid, ctime, mtime);
1765 fclose(fh);
2130 load_fs(FILE * fh, int swapit)
2134 if((fseek(fh, 0, SEEK_END) < 0) || ((ssize_t)(fssize = ftell(fh)) == -1))
2136 rewind(fh);
2142 if(fread(fs, BLOCKSIZE, fssize, fh) != fssize)
2159 flist_blocks(filesystem *fs, uint32 nod, FILE *fh)
2165 fprintf(fh, " %d", bk);
2166 fprintf(fh, "\n");
2416 dump_fs(filesystem *fs, FILE * fh, int swapit)
2422 if(fwrite(fs, BLOCKSIZE, nbblocks, fh) < nbblocks)
2435 FILE *fh;
2450 fh = xfopen(dopt[i], "rb");
2451 add2fs_from_file(fs, nod, fh, fs_timestamp, stats);
2452 fclose(fh);
2652 FILE * fh = xfopen(fsin, "rb");
2653 fs = load_fs(fh, bigendian);
2654 fclose(fh);
2705 FILE *fh;
2711 fh = xfopen(fname, "wb");
2712 fprintf(fh, "%d:", get_nod(fs, nod)->i_size);
2713 flist_blocks(fs, nod, fh);
2714 fclose(fh);
2718 FILE * fh = xfopen(fsout, "wb");
2719 dump_fs(fs, fh, bigendian);
2720 fclose(fh);