Home | History | Annotate | Download | only in cctest

Lines Matching refs:buffer

463 static uintptr_t ReadLong(char* buffer, intptr_t* position, int base) {
464 char* end_address = buffer + *position;
465 uintptr_t result = strtoul(buffer + *position, &end_address, base);
467 CHECK(end_address > buffer + *position);
468 *position = end_address - buffer;
480 char buffer[kBufSize];
481 int length = read(fd, buffer, kBufSize);
483 CHECK_LT(length, kBufSize); // Make the buffer bigger.
486 if (buffer[line_start] == '\n') {
491 uintptr_t start = ReadLong(buffer, &position, 16);
492 CHECK_EQ(buffer[position++], '-');
493 uintptr_t end = ReadLong(buffer, &position, 16);
494 CHECK_EQ(buffer[position++], ' ');
495 CHECK(buffer[position] == '-' || buffer
496 bool read_permission = (buffer[position++] == 'r');
497 CHECK(buffer[position] == '-' || buffer[position] == 'w');
498 bool write_permission = (buffer[position++] == 'w');
499 CHECK(buffer[position] == '-' || buffer[position] == 'x');
500 bool execute_permission = (buffer[position++] == 'x');
501 CHECK(buffer[position] == '-' || buffer[position] == 'p');
502 bool private_mapping = (buffer[position++] == 'p');
503 CHECK_EQ(buffer[position++], ' ');
504 uintptr_t offset = ReadLong(buffer, &position, 16);
506 CHECK_EQ(buffer[position++], ' ');
507 uintptr_t major = ReadLong(buffer, &position, 16);
509 CHECK_EQ(buffer[position++], ':');
510 uintptr_t minor = ReadLong(buffer, &position, 16);
512 CHECK_EQ(buffer[position++], ' ');
513 uintptr_t inode = ReadLong(buffer, &position, 10);
514 while (position < length && buffer[position] != '\n') position++;