Fill in a FileInfoBlock structure concerning a file associated with a particular filehandle.
Source position: amigados.pas line 2308
function ExamineFH64( |
Fh: LongInt; |
Fib: PFileInfoBlock; |
Tags: Pointer |
):LongInt; |
Fh |
|
filehandle to examine |
Fib |
|
FileInfoBlock where the result of the examination is stored |
Tags |
|
tags, no tags defined for now |
=0 fail, <> 0 success
Fill in a FileInfoBlock structure where TFileHandle.fib_Size64 containing the size of the file. TFileHandle.fib_NumBlocks64 contains the number of blocks for the file.
|
Fill in a FileInfoBlock structure concerning a file or directory associated with a particular lock. |
program ExamineFH64Test; uses AmigaDOS; var FH: BPTR; FIB: PFileInfoBlock; begin FH := DOSOpen('c:dir', MODE_OLDFILE); FIB := AllocDosObject(DOS_FIB, nil); if Assigned(FIB) and (FH <> 0) then begin if Boolean(ExamineFH64(FH, FIB, nil)) then writeln('Size: ', FIB^.fib_size64); end; if Assigned(FIB) then FreeDosObject(DOS_FIB, FIB); if FH <> 0 then DOSClose(FH); end.