Home | History | Annotate | Download | only in tests

Lines Matching refs:len

39 dump_str(const char *str, const unsigned int len)
44 for (i = 0; i < len; i += 16) {
45 unsigned int n = len - i > 16 ? 16 : len - i;
56 print_hex(const char *str, const unsigned int len)
61 for (i = 0; i < len; ++i) {
82 test_dump(const unsigned int len)
88 buf = (void *) (((size_t) buf + ps1) & ~ps1) - len;
90 buf = tail_alloc(len);
93 const off_t offset = 0xdefaceddeadbeefLL + len;
94 long rc = pread(0, buf, len, offset);
95 if (rc != (int) len)
97 len, rc);
100 print_hex(buf, len);
101 tprintf("\", %d, %lld) = %ld\n", len, (long long) offset, rc);
102 dump_str(buf, len);
105 for (i = 0; i < len; ++i)
108 rc = pwrite(1, buf, len, offset);
109 if (rc != (int) len)
111 len, rc);
114 print_hex(buf, len);
115 tprintf("\", %d, %lld) = %ld\n", len, (long long) offset, rc);
116 dump_str(buf, len);
118 if (!len)