Lines Matching +full:512 +full:- +full:bytes
1 /*-
36 #include <atf-c.h>
41 /* Use a pre-existing buffer. */
42 char buf[512];
43 char buf2[512];
63 /* Re-open the FILE * to read back the data. */
83 /* Now open a FILE * on the first 4 bytes of the string. */
88 * Try to write more bytes than we shoud, we'll get a short count (4).
97 /* Check that the string was not modified after the first 4 bytes. */
111 fp = fmemopen(NULL, 512, "w+");
115 for (i = 0; i < 512; i++) {
122 ATF_REQUIRE(pos == 512);
133 fp = fmemopen(NULL, 512, "r");
137 fp = fmemopen(NULL, 512, "w");
151 char buf[512] = {'\0'};
154 char str3[sizeof(str) + sizeof(str2) -1];
198 ATF_REQUIRE(strncmp(str3, str, sizeof(str) - 1) == 0);
199 ATF_REQUIRE(strncmp(str3 + sizeof(str) - 1, str2, sizeof(str2)) == 0);
210 * Make sure that NULL bytes are never appended when opening a buffer
220 /* Pre-fill the buffer. */
231 /* Make sure that the buffer doesn't contain any NULL bytes. */
256 /* Make sure that a pre-allocated buffer behaves correctly. */
277 * PR281953 - ensure we cannot write in read-only only mode, and cannot read in
278 * write-only mode.