Home
last modified time | relevance | path

Searched refs:file (Results 1 – 25 of 113) sorted by relevance

12345

/system/core/libzipfile/
Dcentraldir.c36 read_central_dir_values(Zipfile* file, const unsigned char* buf, int len) in read_central_dir_values() argument
45 file->disknum = read_le_short(&buf[0x04]); in read_central_dir_values()
46 file->diskWithCentralDir = read_le_short(&buf[0x06]); in read_central_dir_values()
47 file->entryCount = read_le_short(&buf[0x08]); in read_central_dir_values()
48 file->totalEntryCount = read_le_short(&buf[0x0a]); in read_central_dir_values()
49 file->centralDirSize = read_le_int(&buf[0x0c]); in read_central_dir_values()
50 file->centralDirOffest = read_le_int(&buf[0x10]); in read_central_dir_values()
51 file->commentLen = read_le_short(&buf[0x14]); in read_central_dir_values()
53 if (file->commentLen > 0) { in read_central_dir_values()
54 if (EOCD_LEN + file->commentLen > len) { in read_central_dir_values()
[all …]
Dzipfile.c14 Zipfile *file = malloc(sizeof(Zipfile)); in init_zipfile() local
15 if (file == NULL) return NULL; in init_zipfile()
16 memset(file, 0, sizeof(Zipfile)); in init_zipfile()
17 file->buf = data; in init_zipfile()
18 file->bufsize = size; in init_zipfile()
20 err = read_central_dir(file); in init_zipfile()
23 return file; in init_zipfile()
25 free(file); in init_zipfile()
32 Zipfile* file = (Zipfile*)f; in release_zipfile() local
33 Zipentry* entry = file->entries; in release_zipfile()
[all …]
/system/extras/tests/sdcard/
Dprofile_sdcard.sh32 local file="/tmp/sdcard-scalability.txt"
33 rm -f ${file}
34 echo "# Scalability tests" | tee -a ${file}
35 echo "# Kernel: $(print_kernel)" | tee -a ${file}
36 echo "# Sched features: $(print_sched_features)" | tee -a ${file}
37 echo "# StopWatch scalability total/cumulative duration 0.0 Samples: 1" | tee -a ${file}
38 echo "# Process Time" | tee -a ${file}
42 echo "$p $t" | tee -a ${file}
/system/core/adb/
DSYNC.TXT1 This file tries to document file related requests a client can make
28 SEND - Send a file to device
29 RECV - Retreive a file from device
32 STAT - Stat a file
33 ULNK - Unlink (remove) a file. (Not currently supported)
44 2. A four-byte integer representing file mode.
45 3. A four-byte integer representing file size.
47 5. A four-byte integer representing file name length.
48 6. length number of bytes containing an utf-8 string representing the file
54 The remote file name is split into two parts separated by the last
[all …]
Dadb_auth_host.c193 static int generate_key(const char *file) in generate_key() argument
202 D("generate_key '%s'\n", file); in generate_key()
215 f = fopen(file, "w"); in generate_key()
217 D("Failed to open '%s'\n", file); in generate_key()
229 if (!write_public_keyfile(rsa, file)) { in generate_key()
245 static int read_key(const char *file, struct listnode *list) in read_key() argument
250 D("read_key '%s'\n", file); in read_key()
252 f = fopen(file, "r"); in read_key()
254 D("Failed to open '%s'\n", file); in read_key()
403 char *file; in adb_auth_get_userkey() local
[all …]
/system/core/libnativebridge/tests/
DAndroid.mk28 $(foreach file,$(test_src_files), \
33 $(eval LOCAL_SRC_FILES := $(file)) \
34 $(eval LOCAL_MODULE := $(notdir $(file:%.cpp=%))) \
38 $(foreach file,$(test_src_files), \
43 $(eval LOCAL_SRC_FILES := $(file)) \
44 $(eval LOCAL_MODULE := $(notdir $(file:%.cpp=%))) \
/system/extras/tests/bionic/libstdc++/
DAndroid.mk30 $(foreach file,$(1), \
32 $(eval LOCAL_SRC_FILES := $(file)) \
33 $(eval LOCAL_MODULE := $(notdir $(file:%.cpp=%))) \
45 $(foreach file,$(1), \
47 $(eval LOCAL_SRC_FILES := $(file)) \
48 $(eval LOCAL_MODULE := $(notdir $(file:%.cpp=%))) \
/system/extras/tests/cpueater/
Ddaemonize.c36 char *file = 0; in main() local
53 file = *argv; in main()
55 file = *++argv; in main()
71 if (file) { in main()
72 if(open(file, O_WRONLY|mode|O_CREAT, 0666) < 0) { in main()
73 perror(file); in main()
/system/core/fastbootd/other/sign/src/
DSignImg.java52 File file = new File(path); in getPrivateKey() local
53 FileInputStream fis = new FileInputStream(file); in getPrivateKey()
54 byte[] data = new byte[(int)file.length()]; in getPrivateKey()
68 File file = new File(path); in getContent() local
69 FileInputStream fis = new FileInputStream(file); in getContent()
70 byte[] data = new byte[(int)file.length()]; in getContent()
80 File file = new File(path); in getCMSContent() local
81 FileInputStream fis = new FileInputStream(file); in getCMSContent()
82 byte[] data = new byte[(int)file.length()]; in getCMSContent()
91 File file = new File(path); in readCert() local
[all …]
/system/core/libcutils/
Dcpu_info.c31 FILE* file; in get_cpu_serial_number() local
36 file = fopen("proc/cpuinfo", "r"); in get_cpu_serial_number()
37 if (! file) in get_cpu_serial_number()
40 while ((chp = fgets(serial_number, sizeof(serial_number), file)) != NULL) in get_cpu_serial_number()
78 fclose(file); in get_cpu_serial_number()
Dtrace.c100 FILE * file = fopen("/proc/self/cmdline", "r"); in atrace_is_app_tracing_enabled() local
101 if (file) { in atrace_is_app_tracing_enabled()
103 if (fgets(cmdline, sizeof(cmdline), file)) { in atrace_is_app_tracing_enabled()
108 fclose(file); in atrace_is_app_tracing_enabled()
/system/core/toolbox/
Dtouch.c46 char *file = 0; in touch_main() local
79 file = argv[i]; in touch_main()
83 if (! file) { in touch_main()
88 if (access(file, F_OK)) in touch_main()
89 if ((fd=creat(file, 0666)) != -1) in touch_main()
106 fprintf(stderr, "file = %s\n", file); in touch_main()
112 return utimensat(AT_FDCWD, file, times, flags); in touch_main()
Dinsmod.c51 void *file; in insmod_main() local
63 file = read_file(argv[1], &size); in insmod_main()
64 if (!file) { in insmod_main()
85 ret = init_module(file, size, opts); in insmod_main()
93 free(file); in insmod_main()
Duptime.c92 FILE* file = fopen("/proc/uptime", "r"); in uptime_main() local
93 if (!file) { in uptime_main()
97 if (fscanf(file, "%*f %f", &idle_time) != 1) { in uptime_main()
99 fclose(file); in uptime_main()
102 fclose(file); in uptime_main()
Dtop.c232 FILE *file; in read_procs() local
245 file = fopen("/proc/stat", "r"); in read_procs()
246 if (!file) die("Could not open /proc/stat.\n"); in read_procs()
247 fscanf(file, "cpu %lu %lu %lu %lu %lu %lu %lu", &new_cpu.utime, &new_cpu.ntime, &new_cpu.stime, in read_procs()
249 fclose(file); in read_procs()
330 FILE *file; in read_stat() local
333 file = fopen(filename, "r"); in read_stat()
334 if (!file) return 1; in read_stat()
335 fgets(buf, MAX_LINE, file); in read_stat()
336 fclose(file); in read_stat()
[all …]
/system/extras/cpustats/
Dcpustats.c187 FILE *file; in get_cpu_count_from_file() local
191 file = fopen(filename, "r"); in get_cpu_count_from_file()
192 if (!file) die("Could not open %s\n", filename); in get_cpu_count_from_file()
193 if (!fgets(line, MAX_BUF_SIZE, file)) die("Could not get %s contents\n", filename); in get_cpu_count_from_file()
194 fclose(file); in get_cpu_count_from_file()
212 FILE *file; in get_freq_scales_count() local
218 file = fopen(filename, "r"); in get_freq_scales_count()
219 if (!file) die("Could not open %s\n", filename); in get_freq_scales_count()
222 fscanf(file, "%lu %*d\n", &freq); in get_freq_scales_count()
225 fclose(file); in get_freq_scales_count()
[all …]
/system/media/camera/docs/
Dmetadata-parser-sanity-check34 local file="$1"
36 results="$(python "$file" 2>&1)"
41 echo "FAILED: Unit tests $file"
43 echo "SUCCESS: Unit tests $file"
/system/core/include/zipfile/
Dzipfile.h33 void release_zipfile(zipfile_t file);
38 zipentry_t lookup_zipentry(zipfile_t file, const char* entryName);
52 zipentry_t iterate_zipfile(zipfile_t file, void** cookie);
/system/core/toolbox/upstream-netbsd/usr.bin/grep/
Dfile.c78 grep_refill(struct file *f) in grep_refill()
139 grep_fgetln(struct file *f, size_t *lenp) in grep_fgetln()
201 static inline struct file *
202 grep_file_init(struct file *f) in grep_file_init()
234 struct file *
237 struct file *f; in grep_open()
257 grep_close(struct file *f) in grep_close()
Dgrep.h84 struct file { struct
93 char *file; argument
155 void grep_close(struct file *f);
156 struct file *grep_open(const char *path);
157 char *grep_fgetln(struct file *f, size_t *len);
/system/core/libutils/tests/
DAndroid.mk27 $(foreach file,$(test_src_files), \
31 $(eval LOCAL_SRC_FILES := $(file)) \
32 $(eval LOCAL_MODULE := $(notdir $(file:%.cpp=%))) \
/system/vold/tests/
DAndroid.mk27 $(foreach file,$(test_src_files), \
32 $(eval LOCAL_SRC_FILES := $(file)) \
33 $(eval LOCAL_MODULE := $(notdir $(file:%.cpp=%))) \
/system/core/logd/
DLogCommand.cpp77 FILE *file = fopen(filename, "r"); in clientHasLogCredentials() local
78 if (!file) { in clientHasLogCredentials()
86 while (fgets(line, sizeof(line), file)) { in clientHasLogCredentials()
123 fclose(file); in clientHasLogCredentials()
/system/core/libsparse/
Dbacked_block.c37 } file; member
84 return bb->file.filename; in backed_block_filename()
97 return bb->file.offset; in backed_block_file_offset()
117 free(bb->file.filename); in backed_block_destroy()
224 if (a->file.filename != b->file.filename || in merge_bb()
225 a->file.offset + a->len != b->file.offset) { in merge_bb()
335 bb->file.filename = strdup(filename); in backed_block_add_file()
336 bb->file.offset = offset; in backed_block_add_file()
390 new_bb->file.offset += max_len; in backed_block_split()
/system/extras/tests/bionic/libc/
DAndroid.mk29 $(foreach file,$(1), \
31 $(eval LOCAL_SRC_FILES := $(file)) \
32 $(eval LOCAL_MODULE := $(notdir $(file:%.c=%))) \
47 $(foreach file,$(1), \
49 $(eval LOCAL_SRC_FILES := $(file)) \
50 $(eval LOCAL_MODULE := $(notdir $(file:%.c=%))) \

12345