Lines Matching defs:file
4 * Module Name: cmfsize - Common get file size function
21 * PARAMETERS: file - Open file descriptor
25 * DESCRIPTION: Get the size of a file. Uses seek-to-EOF. File must be open.
26 * Does not disturb the current file pointer.
29 u32 cm_get_file_size(ACPI_FILE file)
35 /* Save the current file pointer, seek to EOF to obtain file size */
37 current_offset = ftell(file);
42 status = fseek(file, 0, SEEK_END);
47 file_size = ftell(file);
52 /* Restore original file pointer */
54 status = fseek(file, current_offset, SEEK_SET);
62 fprintf(stderr, "Could not get file offset\n");
66 fprintf(stderr, "Could not set file offset\n");