/system/extras/tests/lib/testUtil/ |
H A D | testUtil.c | 393 FILE *fp; local 402 if ((fp = popen(cmd, "r")) == NULL) { 408 while (fgets(str, sizeof(str), fp) != NULL) { 417 status = pclose(fp);
|
/system/extras/ioshark/ |
H A D | compile_ioshark.c | 523 FILE *fp; local 558 fp = fopen(infile, "r"); 559 if (fp == NULL) { 564 while (fgets(in_buf, 2048, fp)) { 654 fclose(fp); 658 fp = fopen(outfile, "w+"); 659 if (fp == NULL) { 666 if (ioshark_write_header(fp, &header) != 1) { 671 files_db_write_objects(fp); 676 if (ioshark_write_file_op(fp, disk_file_o [all...] |
/system/extras/showmap/ |
H A D | showmap.cpp | 176 FILE *fp; local 183 fp = fopen(fn, "r"); 184 if (fp == 0) { 189 while (fgets(line, sizeof(line), fp) != 0) { 211 fclose(fp);
|
/system/update_engine/common/ |
H A D | utils.cc | 327 // Reads from an open file |fp|, appending the read content to the container 332 static bool Read(FILE* fp, off_t size, T* out_p) { argument 333 CHECK(fp); 341 size_t nbytes = fread(buf, 1, bytes_to_read, fp); 351 if (ferror(fp)) { 354 return size == 0 || feof(fp); 367 base::ScopedFILE fp(fopen(path.c_str(), "r")); 368 if (!fp.get()) 376 TEST_AND_RETURN_FALSE_ERRNO(fseek(fp.get(), offset, SEEK_SET) == 0); 378 return Read(fp 384 FILE* fp = popen(cmd.c_str(), "r"); local [all...] |
/system/extras/ANRdaemon/ |
H A D | ANRdaemon.cpp | 131 FILE *fp = NULL; local 134 if ((fp = fopen("/proc/stat", "r")) == NULL) { 138 if (fscanf(fp, params, &cpu->utime, &cpu->ntime, 146 fclose(fp); 153 fclose(fp);
|
/system/extras/simpleperf/ |
H A D | record_file_writer.cpp | 47 FILE* fp = fopen(filename.c_str(), "web+"); local 48 if (fp == nullptr) { 53 return std::unique_ptr<RecordFileWriter>(new RecordFileWriter(filename, fp)); 56 RecordFileWriter::RecordFileWriter(const std::string& filename, FILE* fp) argument 58 record_fp_(fp),
|
H A D | cmd_report_sample.cpp | 126 // 2. Prepare report fp. 128 std::unique_ptr<FILE, decltype(&fclose)> fp(nullptr, fclose); 134 fp.reset(fopen(report_filename_.c_str(), open_mode)); 135 if (fp == nullptr) { 139 report_fp_ = fp.get(); 245 std::unique_ptr<FILE, decltype(&fclose)> fp(fopen(filename.c_str(), "rb"), 247 if (fp == nullptr) { 251 ProtobufFileReader protobuf_reader(fp.get());
|
H A D | sample_tree.h | 344 void DisplaySamples(FILE* fp, const std::vector<EntryT*>& samples, argument 350 displayer_.PrintNames(fp); 352 displayer_.PrintSample(fp, sample);
|
H A D | utils.cpp | 104 void FprintIndented(FILE* fp, size_t indent, const char* fmt, ...) { argument 107 fprintf(fp, "%*s", static_cast<int>(indent * 2), ""); 108 vfprintf(fp, fmt, ap);
|
H A D | record_file.h | 69 RecordFileWriter(const std::string& filename, FILE* fp); 163 RecordFileReader(const std::string& filename, FILE* fp);
|
H A D | record_file_reader.cpp | 74 FILE* fp = fopen(filename.c_str(), mode.c_str()); local 75 if (fp == nullptr) { 79 auto reader = std::unique_ptr<RecordFileReader>(new RecordFileReader(filename, fp)); 87 RecordFileReader::RecordFileReader(const std::string& filename, FILE* fp) argument 88 : filename_(filename), record_fp_(fp), event_id_pos_in_sample_records_(0),
|
H A D | read_elf.cpp | 93 FILE* fp = fopen(filename.c_str(), mode.c_str()); local 94 if (fp == nullptr) { 97 ElfStatus result = IsValidElfFile(fileno(fp)); 98 fclose(fp);
|
H A D | utils.h | 146 void FprintIndented(FILE* fp, size_t indent, const char* fmt, ...);
|
H A D | cmd_record_test.cpp | 177 ASSERT_TRUE(RunRecordCmd({"--call-graph", "fp"})); 187 exit(RunRecordCmd({"--call-graph", "fp"}) ? 0 : 1); 193 TEST_IN_ROOT(ASSERT_TRUE(RunRecordCmd({"-a", "--call-graph", "fp"}))); 199 FILE* fp = popen("uname -m", "re"); local 202 fgets(buf, sizeof(buf), fp); 203 pclose(fp);
|
/system/core/logd/ |
H A D | LogStatistics.cpp | 825 FILE* fp = fopen(buffer, "r"); local 826 if (fp) { 827 while (fgets(buffer, sizeof(buffer), fp)) { 832 fclose(fp); 836 fclose(fp); 844 FILE* fp = fopen(buffer, "r"); local 845 if (fp) { 846 while (fgets(buffer, sizeof(buffer), fp)) { 851 fclose(fp); 855 fclose(fp); [all...] |
/system/core/lmkd/tests/ |
H A D | lmkd_test.cpp | 60 FILE* fp = popen(command.c_str(), "r"); local 62 ReadFdToString(fileno(fp), &content); 63 pclose(fp);
|
/system/core/logwrapper/ |
H A D | logwrap.c | 95 FILE *fp; member in struct:log_info 165 fprintf(log_info->fp, "%s\n", line); 342 log_info.fp = fdopen(fd, "a"); 455 fclose(log_info.fp); /* Also closes underlying fd */
|
/system/vold/ |
H A D | VolumeManager.cpp | 417 FILE* fp = setmntent("/proc/mounts", "r"); local 418 if (fp == NULL) { 427 while ((mentry = getmntent(fp)) != NULL) { 433 endmntent(fp); 614 FILE* fp = setmntent("/proc/mounts", "r"); local 615 if (fp == NULL) { 624 while ((mentry = getmntent(fp)) != NULL) { 632 endmntent(fp);
|
/system/netd/tests/ |
H A D | binder_test.cpp | 832 std::vector<uint8_t> fp(SHA256_SIZE); 846 { {"192.0.2.3"}, "@@@@", { fp }, 0 }, 847 { {"2001:db8::4"}, "", { fp }, 0 }, 854 { {"2001:db8::e"}, "", { fp, fp, fp }, 0 }, 855 { {"192.0.2.14"}, "", { fp, short_fp }, EINVAL },
|
/system/core/adb/ |
H A D | adb_auth_host.cpp | 176 std::unique_ptr<FILE, decltype(&fclose)> fp(fopen(file.c_str(), "r"), fclose); 177 if (!fp) { 183 if (!PEM_read_RSAPrivateKey(fp.get(), &key, nullptr, nullptr)) {
|
/system/core/init/ |
H A D | reboot.cpp | 215 std::unique_ptr<std::FILE, int (*)(std::FILE*)> fp(setmntent("/proc/mounts", "r"), endmntent); 216 if (fp == nullptr) { 221 while ((mentry = getmntent(fp.get())) != nullptr) {
|
/system/extras/perfprofd/tests/ |
H A D | perfprofd_test.cc | 300 FILE *fp = fopen(processed.c_str(), "w"); local 302 fprintf(fp, "%d\n", i); 304 fclose(fp); 359 FILE *fp = fopen(config_path.c_str(), "w"); local 360 ASSERT_TRUE(fp != nullptr); 361 fprintf(fp, "%s\n", config_text.c_str()); 362 fclose(fp);
|
/system/core/logcat/ |
H A D | logcat.cpp | 1271 FILE* fp = fopen(devname.c_str(), "web"); local 1273 if (!fp) break; 1277 if(!android::base::WriteFully(fileno(fp), pipePurpose.c_str(), 1279 fclose(fp); 1289 context->output = fp; 1290 context->output_fd = fileno(fp); 1293 context->error = fp; 1294 context->error_fd = fileno(fp);
|
/system/bt/btif/src/ |
H A D | btif_dm.cc | 2639 FILE* fp; local 2656 fp = fopen(path, "wb+"); 2657 if (fp == NULL) { 2663 fwrite(c, 1, BT_OCTET16_LEN, fp); 2664 fwrite(r, 1, BT_OCTET16_LEN, fp); 2665 fclose(fp); 2751 FILE* fp = fopen(path, "rb"); local 2752 if (fp == NULL) { 2758 fread(p_c, 1, BT_OCTET16_LEN, fp); 2759 fread(p_r, 1, BT_OCTET16_LEN, fp); [all...] |
/system/core/libpixelflinger/ |
H A D | scanline.cpp | 2257 const GGLFormat* fp = &(c->formats[cb->format]); local 2259 (x + (cb->stride * y)) * fp->size; 2265 (u + (tex->stride * v)) * fp->size; 2267 const size_t size = ct * fp->size; 2310 const GGLFormat* fp = &(c->formats[cb->format]); local 2312 (x + (cb->stride * y)) * fp->size; 2313 const size_t size = ct * fp->size; 2323 const GGLFormat* fp = &(c->formats[cb->format]); local 2325 (x + (cb->stride * y)) * fp->size; 2326 const size_t size = ct * fp 2348 const GGLFormat* fp = &(c->formats[cb->format]); local [all...] |