Home | History | Annotate | Download | only in pwrite

Lines Matching refs:K1

85 #define K1              1024
86 #define K2 (K1 * 2)
87 #define K3 (K1 * 3)
88 #define K4 (K1 * 4)
116 * Call pwrite() to write K1 bytes of data (0's) at offset 0
119 nwrite = pwrite(fildes, write_buf[0], K1, 0);
122 if (nwrite != K1) {
135 l_seek(fildes, K1 / 2, SEEK_SET, K1 / 2);
138 * Again, pwrite() K1 of data (2's) at offset K2 of
141 nwrite = pwrite(fildes, write_buf[2], K1, K2);
142 if (nwrite != K1) {
150 l_seek(fildes, 0, SEEK_CUR, K1 / 2);
156 * Using write(), write of K1 of data (3's) which
160 nwrite = write(fildes, write_buf[3], K1);
161 if (nwrite != K1) {
170 /* Again, pwrite() K1 of data (1's) at offset K1. */
171 nwrite = pwrite(fildes, write_buf[1], K1, K1);
172 if (nwrite != K1) {
175 K1, TEMPFILE, errno, strerror(errno));
235 write_buf[count] = malloc(K1);
240 memset(write_buf[count], count, K1);
276 read_buf = malloc(K1);
284 offloc = lseek(fildes, count * K1, SEEK_SET);
285 if (offloc != (count * K1)) {
292 nread = read(fildes, read_buf, K1);
293 if (nread != K1) {
299 if (memcmp(write_buf[count], read_buf, K1) != 0) {