/system/extras/fatblock/ |
H A D | fatblock.c | 52 static int read_callback(char *buf, uint64_t length, uint64_t offset) argument 57 result = fs_read(&fs, buf, offset, length); 66 static int write_callback(const char *buf, uint64_t length, uint64_t offset) argument
|
H A D | read.c | 28 static int buffer_read(char *buf, offset_t buf_len, char *out, argument 31 assert(buf); 47 memcpy(out, buf + off, len); 72 static int file_read(struct file *f, char *buf, offset_t off, offset_t len) argument 79 assert(buf); 114 ret = read(fd, buf, (size_t)len); 126 static int dir_read(struct dir *d, char *buf, offset_t off, offset_t len) argument 129 assert(buf); 131 return buffer_read((char*)d->entries, d->size, buf, off, len); 134 static int extent_read(struct fs *fs, struct extent *e, char *buf, argument 161 fs_read(struct fs *fs, char *buf, offset_t start, offset_t len) argument [all...] |
/system/extras/librank/ |
H A D | librank.c | 49 static int getprocname(pid_t pid, char *buf, size_t len); 314 static int getprocname(pid_t pid, char *buf, size_t len) { argument 320 if (!f) { *buf = '\0'; return 1; } 321 if (!fgets(buf, len, f)) { *buf = '\0'; return 2; }
|
/system/extras/procrank/ |
H A D | procrank.c | 34 static int getprocname(pid_t pid, char *buf, int len); 301 * buf of length len. The size of the buffer must be greater than zero to get 313 static int getprocname(pid_t pid, char *buf, int len) { argument 334 if (fgets(buf, len, f) == NULL) { 350 if (strlcpy(buf, unknown_cmdline, (size_t)len) >= (size_t)len) {
|
/system/extras/sane_schedstat/ |
H A D | sane_schedstat.c | 144 char buf[4096]; local 149 i = read(fd, buf, sizeof(buf) - 1); 151 buf[i] = '\0'; 152 if (parse(buf)) return -1;
|
/system/extras/sound/ |
H A D | playwav.c | 37 int (*fill)(void *buf, unsigned sz, void *cookie), 43 char buf[8192]; local 64 if (sz > sizeof(buf)) { 71 if (fill(buf, sz, cookie)) 73 if (write(afd, buf, sz) != sz) 85 if (fill(buf, sz, cookie)) 87 if (write(afd, buf, sz) != sz) 125 int fill_buffer(void *buf, unsigned sz, void *cookie) argument 129 memcpy(buf, next, sz); 194 unsigned char buf[819 local 36 pcm_play(unsigned rate, unsigned channels, int (*fill)(void *buf, unsigned sz, void *cookie), void *cookie) argument 297 char buf[64*1024]; local [all...] |
/system/extras/tests/bionic/libc/common/ |
H A D | test_strptime.c | 27 char buf[255]; local 33 strftime(buf, sizeof(buf), "%H:%M", &tm); 34 puts(buf); 35 puts(!strcmp(buf, "11:14") ? "OK" : "FAILED"); 39 strftime(buf, sizeof(buf), "%H:%M:%S", &tm); 40 puts(buf); 41 puts(!strcmp(buf, "09:41:53") ? "OK" : "FAILED");
|
H A D | test_udp.c | 45 char buf[BUFLEN]; local 89 if (recvfrom(s, buf, BUFLEN, 0, (struct sockaddr*)&si_other, (socklen_t*)&slen)==-1) 92 inet_ntoa(si_other.sin_addr), ntohs(si_other.sin_port), buf); 112 sprintf(buf, "This is packet %d\n", i); 113 if (sendto(s, buf, BUFLEN, 0, (struct sockaddr*)&si_other, slen)==-1)
|
/system/extras/tests/bionic/libc/glibc/assert/ |
H A D | test-assert.c | 15 char buf[160]; variable 75 fgets (buf, 160, stderr); 76 if (!strstr (buf, "1 == 2")) 79 fgets (buf, 160, stderr); 80 if (strstr (buf, "1 == 1")) 83 fgets (buf, 160, stderr); 84 if (strstr (buf, "2 == 3"))
|
/system/extras/tests/directiotest/ |
H A D | directiotest.c | 70 static ssize_t do_read(int fd, void *buf, off64_t start, size_t count) argument 78 ret = read(fd, (char *)buf + bytes_read, count - bytes_read); 92 static ssize_t do_write(int fd, const void *buf, off64_t start, size_t count) argument 100 ret = write(fd, (char *)buf + bytes_out, count - bytes_out); 122 static void init_test_buf(void *buf, uint64_t start_blk, size_t len) argument 124 uint32_t *data = buf; 132 static void dump_hex(const void *buf, int len) argument 134 const uint8_t *data = buf;
|
/system/extras/tests/ext4/ |
H A D | rand_emmc_perf.c | 48 char buf[TST_BLK_SIZE] = { 0 }; local 108 if (write(fd, buf, sizeof(buf)) != sizeof(buf)) { 112 if (read(fd, buf, sizeof(buf)) != sizeof(buf)) {
|
/system/extras/tests/lib/testUtil/ |
H A D | testUtil.c | 310 * pointed to by buf, for the number of bytes given by size. 319 testXDump(const void *buf, size_t size) argument 324 const unsigned char *ptr = buf, *start = buf;
|
/system/media/audio_utils/ |
H A D | resampler.c | 107 struct resampler_buffer buf; local 108 buf.frame_count = rsmp->frames_needed - rsmp->frames_in; 109 rsmp->provider->get_next_buffer(rsmp->provider, &buf); 110 if (buf.raw == NULL) { 114 buf.raw, 115 buf.frame_count * rsmp->channel_count * sizeof(int16_t)); 116 rsmp->frames_in += buf.frame_count; 117 rsmp->provider->release_buffer(rsmp->provider, &buf);
|
/system/media/camera/tests/ |
H A D | camera_metadata_tests.cpp | 75 void *buf = NULL; local 85 buf = malloc(buf_size); 87 EXPECT_NOT_NULL(buf); 89 m = place_camera_metadata(buf, buf_size, entry_capacity, data_capacity); 91 EXPECT_EQ(buf, (uint8_t*)m); 97 free(buf); 102 void *buf = NULL; local 114 buf = malloc(buf_size); 116 EXPECT_NOT_NULL(buf); 118 m = place_camera_metadata(buf, buf_siz 127 uint8_t *buf = NULL; local 371 uint8_t *buf = (uint8_t*)malloc(buf_size); local 426 uint8_t *buf = (uint8_t*)malloc(buf_size); local 484 uint8_t *buf = (uint8_t*)malloc(buf_size); local [all...] |
/system/netd/ |
H A D | InterfaceController.h | 24 char *buf; member in struct:android_wifi_priv_cmd
|