• Home
  • Raw
  • Download

Lines Matching refs:len

69     size_t len = PAGE_SIZE;  variable
70 size_t expandSize = len * 2;
75 char *mem = (char *)mmap(nullptr, len, prot, flags, -1, 0);
79 mem = (char *)mremap(mem, len, expandSize, 0);
87 mem[len - 1] = testChar + 3;
89 mem[len + 0] = testChar;
93 LOG("mem[len - 1] = 0x%02x", mem[len - 1]);
94 LOG("mem[len + 0] = 0x%02x", mem[len + 0]);
111 size_t len = PAGE_SIZE * 2; variable
112 size_t shrinkSize = len / 2;
117 char *mem = (char *)mmap(nullptr, len, prot, flags, -1, 0);
121 mem = (char *)mremap(mem, len, shrinkSize, 0);
149 size_t len = PAGE_SIZE; variable
150 size_t expandSize = len * 2;
157 char *mem = (char *)mmap(nullptr, len, prot, flags, -1, 0);
161 mem = (char *)mremap(mem, len, expandSize, reFlag, (void *)fixAddr);
169 fixAddr[len - 1] = testChar + 3;
171 fixAddr[len + 0] = testChar;
175 LOG("fixAddr[len - 1] = 0x%02x", fixAddr[len - 1]);
176 LOG("fixAddr[len + 0] = 0x%02x", fixAddr[len + 0]);
193 size_t len = PAGE_SIZE * 2; variable
194 size_t shrinkSize = len / 2;
201 char *mem = (char *)mmap(nullptr, len, prot, flags, -1, 0);
205 mem = (char *)mremap(mem, len, shrinkSize, reFlag, (void *)fixAddr);
233 size_t len = PAGE_SIZE; variable
234 size_t expandSize = len * 2;
247 char *mem = (char *)mmap(nullptr, len, prot, flags, fd, 0);
251 mem = (char *)mremap(mem, len, expandSize, 0);
259 mem[len - 1] = testChar + 3;
261 mem[len + 0] = testChar;
264 LOG("mem[len - 1] = 0x%02x", mem[len - 1]);
265 LOG("mem[len + 0] = 0x%02x", mem[len + 0]);
285 size_t len = PAGE_SIZE * 2; variable
286 size_t shrinkSize = len / 2;
296 int wByte = write(fd, buf, len);
299 char *mem = (char *)mmap(nullptr, len, prot, flags, fd, 0);
303 mem = (char *)mremap(mem, len, shrinkSize, 0);
335 size_t len = PAGE_SIZE; variable
336 size_t expandSize = len * 2;
351 char *mem = (char *)mmap(nullptr, len, prot, flags, fd, 0);
355 mem = (char *)mremap(mem, len, expandSize, reFlag, (void *)fixAddr);
363 fixAddr[len - 1] = testChar + 3;
365 fixAddr[len + 0] = testChar;
369 LOG("fixAddr[len - 1] = 0x%02x", fixAddr[len - 1]);
370 LOG("fixAddr[len + 0] = 0x%02x", fixAddr[len + 0]);
390 size_t len = PAGE_SIZE * 2; variable
391 size_t shrinkSize = len / 2;
404 int wByte = write(fd, buf, len);
407 char *mem = (char *)mmap(nullptr, len, prot, flags, fd, 0);
411 mem = (char *)mremap(mem, len, shrinkSize, reFlag, (void *)fixAddr);
446 size_t len = PAGE_SIZE; variable
449 mem = mmap((void *)fixAddr, len, PROT_READ | PROT_WRITE, MAP_ANON|MAP_PRIVATE, -1, 0);
454 newMem = mremap((void *)fixAddr, len, len, 0);
459 newMem = mremap(mem, len, len, 0x04);
464 newMem = mremap(mem, len, 0, 0);
469 EXPECT_TRUE(munmap(mem, len) == 0) << "ERROR: munmap() != 0";
472 EXPECT_TRUE(munmap(newMem, len) == 0) << "ERROR: munmap() != 0" << errno;