2005-11-19 00:30 UTC+0100 Viktor Szakats (viktor.szakats/syenar.hu)

* include/hbapifs.c
   * src/rtl/filesys.c
     ! hb_fsSetDevMode() fixed back to return a BOOL value
       to be compatible with the CA-Cl*pper undocumented
       _tdevraw() function. (hb_fsSetDevMove() is mapped
       to _tdevraw() in hbundoc.api, it's the documented
       version of the same functionality)
       Also fixed warning and error for one of the dummy
       platform branches.
       Since this came from xHarbour it pbly needs to be
       fixed there too.

   * tests/Makefile
     + symbolt.prg added
This commit is contained in:
Viktor Szakats
2005-11-18 23:32:30 +00:00
parent 60d25d7eef
commit a72904f14a
4 changed files with 34 additions and 4 deletions

View File

@@ -8,6 +8,22 @@
2002-12-01 13:30 UTC+0100 Foo Bar <foo.bar@foobar.org>
*/
2005-11-19 00:30 UTC+0100 Viktor Szakats (viktor.szakats/syenar.hu)
* include/hbapifs.c
* src/rtl/filesys.c
! hb_fsSetDevMode() fixed back to return a BOOL value
to be compatible with the CA-Cl*pper undocumented
_tdevraw() function. (hb_fsSetDevMove() is mapped
to _tdevraw() in hbundoc.api, it's the documented
version of the same functionality)
Also fixed warning and error for one of the dummy
platform branches.
Since this came from xHarbour it pbly needs to be
fixed there too.
* tests/Makefile
+ symbolt.prg added
2005-11-16 13:35 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/bin/pack_src.sh
* updated for nulsys.prg -> nulsys.c modification

View File

@@ -143,7 +143,7 @@ extern BOOL HB_EXPORT hb_fsRename ( BYTE * pszOldName, BYTE * pszNewName
extern ULONG HB_EXPORT hb_fsSeek ( FHANDLE hFileHandle, LONG lOffset, USHORT uiMode ); /* reposition an open file */
extern HB_FOFFSET HB_EXPORT hb_fsSeekLarge( FHANDLE hFileHandle, HB_FOFFSET llOffset, USHORT uiFlags ); /* reposition an open file using 64bit API */
extern ULONG HB_EXPORT hb_fsTell ( FHANDLE hFileHandle ); /* retrieve the current position of a file */
extern void HB_EXPORT hb_fsSetDevMode ( FHANDLE hFileHandle, USHORT uiDevMode ); /* change the device mode of a file (text/binary) */
extern BOOL HB_EXPORT hb_fsSetDevMode ( FHANDLE hFileHandle, USHORT uiDevMode ); /* change the device mode of a file (text/binary) */
extern void HB_EXPORT hb_fsSetError ( USHORT uiError ); /* set the file system DOS error number */
extern void HB_EXPORT hb_fsSetIOError ( BOOL fResult, USHORT uiOperation ); /* set the file system error number after IO operation */
extern USHORT HB_EXPORT hb_fsWrite ( FHANDLE hFileHandle, BYTE * pBuff, USHORT ulCount ); /* write to an open file from a buffer (<=64K) */

View File

@@ -796,7 +796,7 @@ void HB_EXPORT hb_fsClose( FHANDLE hFileHandle )
#endif
}
void HB_EXPORT hb_fsSetDevMode( FHANDLE hFileHandle, USHORT uiDevMode )
BOOL HB_EXPORT hb_fsSetDevMode( FHANDLE hFileHandle, USHORT uiDevMode )
{
HB_TRACE(HB_TR_DEBUG, ("hb_fsSetDevMode(%p, %hu)", hFileHandle, uiDevMode));
@@ -816,7 +816,10 @@ void HB_EXPORT hb_fsSetDevMode( FHANDLE hFileHandle, USHORT uiDevMode )
iRet = setmode( hFileHandle, O_TEXT );
break;
}
hb_fsSetIOError( iRet != -1, 0 );
return iRet != -1;
}
#elif defined(_MSC_VER) || defined(__MINGW32__) || defined(__DMC__)
{
@@ -832,20 +835,30 @@ void HB_EXPORT hb_fsSetDevMode( FHANDLE hFileHandle, USHORT uiDevMode )
iRet = _setmode( hFileHandle, _O_TEXT );
break;
}
hb_fsSetIOError( iRet != -1, 0 );
return iRet != -1;
}
#elif defined( HB_OS_UNIX )
HB_SYMBOL_UNUSED( hFileHandle );
HB_SYMBOL_UNUSED( uiDevMode );
hb_fsSetError( ( USHORT ) FS_ERROR );
return FALSE;
#else
hb_fsSetError( (USHORT) FS_ERROR );
HB_SYMBOL_UNUSED( hFileHandle );
HB_SYMBOL_UNUSED( uiDevMode );
hb_fsSetError( ( USHORT ) FS_ERROR );
return FALSE;
#endif
}
USHORT HB_EXPORT hb_fsRead( FHANDLE hFileHandle, BYTE * pBuff, USHORT uiCount )

View File

@@ -115,6 +115,7 @@ PRG_SOURCES=\
statfun.prg \
statics.prg \
strdelim.prg \
symbolt.prg \
t1.prg \
test_all.prg \
testbrdb.prg \