Hi All,
There is a problem with fopen() and I suspect fcreate(), etc in philes.c. In
philes.c, you will notice that hb_fsOpen is cast to HB_NHANDLE which is
typedef as a pointer to unsigned int in hbdefs.h. This means that the
F_ERROR (-1) is made positive (2^32-1 or +4,294,967,295) so you have an
invalid file pointer if a file doesn't exist.
For example this pgm returns invalid handle 2^32-1
//-----------------------------------------
function main()
? "File Handle:", fopen("Nonsense.file")
return 0
_______________________________________________
Harbour mailing list (attachment size limit: 40KB)
[email protected]
http://lists.harbour-project.org/mailman/listinfo/harbour