2010-01-25 15:23 UTC+0100 Viktor Szakats (harbour.01 syenar.hu)
* contrib/hbnetio/utils/netiocmd.prg
! Fixed remote execution protection to work even when
the source was compiled from another directory.
; QUESTION: Is there a better way to make this kind of
protection? Current system will break if
the source filename of the caller happens to
change in the future.
* contrib/hbnetio/utils/netiosrv.prg
+ Show internal error and quit and if above self-protection
got broken for some reason.
* utils/hbmk2/hbmk2.prg
! Fixed entry function detection builting project in
different than current dir, possibly also in -inc mode.
[TOMERGE 2.0]
This commit is contained in:
@@ -17,6 +17,24 @@
|
||||
past entries belonging to author(s): Viktor Szakats.
|
||||
*/
|
||||
|
||||
2010-01-25 15:23 UTC+0100 Viktor Szakats (harbour.01 syenar.hu)
|
||||
* contrib/hbnetio/utils/netiocmd.prg
|
||||
! Fixed remote execution protection to work even when
|
||||
the source was compiled from another directory.
|
||||
; QUESTION: Is there a better way to make this kind of
|
||||
protection? Current system will break if
|
||||
the source filename of the caller happens to
|
||||
change in the future.
|
||||
|
||||
* contrib/hbnetio/utils/netiosrv.prg
|
||||
+ Show internal error and quit and if above self-protection
|
||||
got broken for some reason.
|
||||
|
||||
* utils/hbmk2/hbmk2.prg
|
||||
! Fixed entry function detection builting project in
|
||||
different than current dir, possibly also in -inc mode.
|
||||
[TOMERGE 2.0]
|
||||
|
||||
2010-01-25 13:23 UTC+0100 Viktor Szakats (harbour.01 syenar.hu)
|
||||
* ChangeLog
|
||||
+ Added TOMERGE to /INSTALL doc modifications.
|
||||
|
||||
@@ -16,8 +16,11 @@
|
||||
FUNCTION hbnetiosrv_LoadCmds( bQuit, bShowInfo )
|
||||
LOCAL hCmds
|
||||
|
||||
LOCAL cName
|
||||
|
||||
/* We add here a little validation to ensure that we can not be hacked. [vailtom] */
|
||||
IF Lower( ProcName( 1 ) + "-" + ProcFile( 1 ) ) != "main-netiosrv.prg"
|
||||
hb_FNameSplit( ProcFile( 1 ), NIL, @cName )
|
||||
IF Lower( ProcName( 1 ) + "-" + cName ) != "main-netiosrv"
|
||||
RETURN NIL
|
||||
ENDIF
|
||||
|
||||
|
||||
@@ -138,6 +138,11 @@ PROCEDURE Main( ... )
|
||||
hCommands := hbnetiosrv_LoadCmds( {|| lQuit := .T. },; /* codeblock to quit */
|
||||
{|| ShowConfig( netiosrv ) } ) /* codeblock to display config both uses local vars */
|
||||
|
||||
IF Empty( hCommands )
|
||||
OutStd( "Internal error", hb_osNewLine() )
|
||||
lQuit := .T.
|
||||
ENDIF
|
||||
|
||||
/* Command prompt */
|
||||
DO WHILE ! lQuit
|
||||
|
||||
|
||||
@@ -3753,7 +3753,7 @@ FUNCTION hbmk( aArgs, /* @ */ lPause )
|
||||
|
||||
/* Do entry function detection on platform required and supported */
|
||||
IF ! hbmk[ _HBMK_lDONTEXEC ] .AND. ! lStopAfterCComp .AND. l_cMAIN == NIL
|
||||
tmp := iif( Lower( FN_ExtGet( hbmk[ _HBMK_cFIRST ] ) ) $ ".prg|.clp" .OR. Empty( FN_ExtGet( hbmk[ _HBMK_cFIRST ] ) ), FN_ExtSet( hbmk[ _HBMK_cFIRST ], ".c" ), hbmk[ _HBMK_cFIRST ] )
|
||||
tmp := iif( Lower( FN_ExtGet( hbmk[ _HBMK_cFIRST ] ) ) $ ".prg|.clp" .OR. Empty( FN_ExtGet( hbmk[ _HBMK_cFIRST ] ) ), FN_DirExtSet( hbmk[ _HBMK_cFIRST ], cWorkDir, ".c" ), hbmk[ _HBMK_cFIRST ] )
|
||||
IF ! Empty( tmp := getFirstFunc( hbmk, tmp ) )
|
||||
l_cMAIN := tmp
|
||||
ENDIF
|
||||
|
||||
Reference in New Issue
Block a user