Converted bz2_au.library into the OS3, OS4 and MorphOS-compatible
[AROS.git] / test / dos / namefromfh.c
blob0b50384f391ec47f35121cc6bfbd3b3b215d96dc
1 #include <proto/dos.h>
2 #include <stdio.h>
4 int main(void)
6 TEXT buffer[512];
7 BPTR fh = Open("__TEST__", MODE_NEWFILE);
9 if (fh != BNULL)
11 if (NameFromFH(fh, buffer, 512))
13 printf("got name: %s\n", buffer);
15 else
17 printf("namefromlock failed. ioerr = %ld\n", IoErr());
20 Close(fh);
21 DeleteFile("__TEST__");
23 else
25 printf("couldn't create file\n");
29 return 0;