13 buffer
= malloc(maxsize
);
15 printf("Enter writesize (< 524288)\n");
16 scanf("%d", &writesize
);
18 fh
= Open("seek_test_file", MODE_NEWFILE
);
19 FWrite(fh
, (STRPTR
)buffer
, writesize
, 1);
21 printf("File pos: %d\n", (int)Seek(fh
, 0, OFFSET_CURRENT
));
22 filepos
= Seek(fh
, writesize
, OFFSET_BEGINNING
);
25 printf("ERROR for size: %d, IoErr: %d\n", (int)writesize
, (int)IoErr());