
Frees a buffer previously allocated with BinaryAlloc.
BinaryFree( handle )
(i) handle: handle of buffer to free.
(i) returns 0.
Use this function to free a binary buffer previously allocated by the BinaryAlloc function. After freeing the buffer, no further operations should be performed on the buffer or its handle.
fs=FileSize("C:\CONFIG.SYS")
binbuf = BinaryAlloc(fs+100)
If binbuf == 0
Message("Error", "BinaryAlloc Failed")
Else
BinaryRead(binbuf, "C:\CONFIG.SYS")
BinaryPokeStr(binbuf, fs, "DEVICE=C:\FLOOGLE.SYS%@crlf%")
BinaryWrite(binbuf, "C:\CONFIG.SYS")
binbuf=BinaryFree(binbuf)
EndIf
Message("BinaryFree", "Done.")