* harbour/src/rtl/hbsockhb.c
* changed return values of some functions: nSuccess to lSuccess
* HB_SOCKET_PF_* changed to HB_SOCKET_AF_*
- hb_parnintdef() (moved to extend.c)
! some bug fixes
! some typo in documentation
* harbour/examples/udpds/udpds.prg
* sychronized with hb_socket*() changes
* changed server thread exit condition (proposed by Przemek)
* harbour/include/hbapi.h
* harbour/src/vm/extend.c
+ hb_parnintdef()
* include/hbapi.h
! Added HB_EXPORT to hb_memvarGet() and hb_memvarSetValue()
used by new OLE server code in hbwin when created -shared
OLE server .dlls.
+ contrib/hbwin/hbolesrv.hbc
+ Added .hbc file to help creating OLE servers.
* contrib/hbwin/tests/olesrv1.hbp
* contrib/hbwin/tests/olesrv2.hbp
* contrib/hbwin/tests/olesrv3.hbp
% Changed to use hbolesrv.hbc.
- Deleted '-static' option to also allow to build -shared
OLE servers. (I tested them OK)
* contrib/hbwin/tests/olesrv2.prg
+ Tweak to allow case-insensitive access of OLE functions.
* utils/hbmk2/hbmk2.prg
+ Added support for .def files in source= .hbc line.
* harbour/include/hbapi.h
* harbour/src/vm/hashes.c
* harbour/src/vm/hashfunc.c
+ added support for keeping strict assign order in hash arrays. It's
enabled optionally by setting HB_HASH_KEEPORDER hash array flag.
It gives the same functionality as associative arrays in xHarbour
(enabled by HSETAACOMPATIBILITY()) but this implementation is
internally completely different. It does not introduce linear
scan in add operation so enabling it should not reduce the
performance in this operation. It can even improve it on some
hardware reducing number of memory bytes which have to be moved.
Only delete operation will force linear index scan. The most
important in this implementation is that it does not need any
additional functions like HAA*() in xHarbour. Just simply all
existing functions operating on position indexes like HB_HPOS(),
HB_HKEYAT(), HB_HVALUEAT(), HB_HPAIRAT(), HB_HDELAT(), HB_HSCAN()
use as index natural order in which items were added to hash array.
Also HB_HKEYS(), HB_HVALUES() and FOR EACH iterations respect it.
+ added new PRG functions
HB_HKEEPORDER( <hValue> [, <lNewSetting> ] ) -> <lPrevSetting>
HB_HSETORDER( <hValue> [, <lNewSetting> ] ) -> <hValue>
which cam be used to enable/disable strict order in hash array.
Enabling strict order for non empty hash arrays accept the order
created after sorting existing item not the original assign order.
Disabling strict order for non empty hash arrays may change the
items order.
; TODO: add translation for xHarbour's HAA*() functions to hbcompat.ch
and/or xhb library.
* harbour/contrib/hbnetio/netiocli.c
* harbour/contrib/hbnetio/netiosrv.c
% reenabled TCP_NODELAY on client and server side
I had to be really tired when I was making tests and I mixed
hb_socketSetNoDelay() with hb_socketSetBlockingIO().
Thanks to Aleksander Czajczynski who noticed the delay in his
tests.
* harbour/contrib/hbwin/olecore.c
* minor cleanup
* harbour/include/hbapi.h
* harbour/include/hbvmint.h
* harbour/include/hbvmopt.h
* harbour/include/hbstack.h
* harbour/include/hbvmpub.h
* harbour/include/hbtypes.h
* harbour/src/vm/estack.c
* harbour/src/vm/hvmall.c
* slightly modified the names of HB_{API|STACK}_MACROS.
These are internal macros in current Harbour code but they are
still defined in some old user build scripts used to compiled
user or core code what could cause unpredictable results for
final binaries. AFAIR default xMate configuration enables them.
* harbour/src/rdd/dbf1.c
* minor cleanup
* harbour/include/hbapi.h
+ added new macro HB_IS_EVALITEM() - returns true for items which can
understand EVAL message i.e. CODEBLOCK and SYMBOL items.
* harbour/contrib/hbwin/axcore.c
* harbour/contrib/hbwin/olecore.c
* harbour/contrib/hbwin/hbwinole.h
* modified hb_oleDispInvoke() function to accept as additional
parameter pointer to HVM item instead of pointer to DISPID.
Such version is more universal.
* harbour/include/hbapi.h
* harbour/src/vm/hashes.c
+ added new C function hb_hashGetCItemPos()
* harbour/src/rtl/hbcom.c
! fixed typo located by Bisz István
* harbour/include/hbapi.h
* harbour/src/vm/dynsym.c
+ added to C functions:
int hb_dynsymToNum( PHB_DYNS pDynSym );
PHB_DYNS hb_dynsymFromNum( int iSymNum );
which can be used to make conversion between dynamic symbols and
numbers
* harbour/src/compiler/hbmain.c
* harbour/src/compiler/harbour.y
* harbour/src/compiler/harbour.yyc
* use hb_compGetFuncID() to detect reserved function names
* harbour/include/hbapi.h
* harbour/src/common/Makefile
- harbour/src/common/reserved.c
- removed not longer used hb_compReservedName() function
* include/hbapi.h
* src/common/hbver.c
+ Added hb_iswin2k() low-level function to detect
if running under Windows 2000 or newer.
* include/hbextern.ch
* src/rtl/version.c
+ Added HB_OSISWIN2K() .prg level function.
* src/rtl/gtwin/gtwin.c
* src/rtl/gtwvt/gtwvt.c
* contrib/gtwvg/gtwvg.c
* contrib/gtwvg/wvggui.c
* examples/gtwvw/gtwvw.c
* contrib/hbwin/win_prn2.c
* contrib/hbwin/win_prn3.c
% Changed to use hb_iswin*() API instead of implementing
version detection locally.
* contrib/hbmysql/mysql.c
* contrib/hbpgsql/postgres.c
+ Added my partial copyright.
* contrib/hbpgsql/tests/tstpgrdd.prg
* Formatting.
* contrib/hbpgsql/postgres.c
! Fixed to define all .prg level functions regardless
of pgsql lib it's built against. They return
permanent failure in this case.
! Fixed PQCREATETRACE() to return NULL pointer instead
of NIL for static builds.
! PQFREECANCEL() marked with HB_LEGACY_LEVEL3.
* contrib/hbwin/win_os.prg
+ Using HB_OSISWIN2K() core API.
* contrib/hbide/ideprojmanager.prg
* Minor alignment.
* src/vm/hvm.c
* include/hbapi.h
* Marked hb_synEval public symbol with HB_LEGACY_LEVEL3
* src/rtl/gtwin/gtwin.c
! Copyright header update.
* src/rtl/objfunc.prg
* include/hboo.ch
* Minor cleanup and formatting.
* INSTALL
* Minor refinement in wording.
* contrib/hbide/hbide.prg
* contrib/hbide/ideactions.prg
* contrib/hbide/idedocks.prg
! "Codec" -> "Encoding" in a few more places.
! "..." added to some more menu items.
! Double "(.ext)" text in filetypes in open project dialog.
; Please review me.
* src/common/hbver.c
* include/hbapi.h
+ Added hb_iswinvista() to detect Vista and newer Windows versions.
* src/rtl/version.c
* include/hbextern.ch
+ Added HB_OSISWINVISTA() .prg level function with above meaning.
* contrib/hbwin/win_os.prg
% Changed to use HB_OSISWINVISTA() instead of hbwin specific
WIN_OSISVISTAORUPPER().
* harbour/include/hbcompdf.h
* harbour/src/vm/macro.c
% changed HB_PCODE_INFO structure to eliminate one memory allocation
in macro compiler
* harbour/include/hbapi.h
* harbour/include/hbvm.h
* harbour/src/vm/codebloc.c
* harbour/src/vm/itemapi.c
* harbour/src/vm/hvm.c
* changed second parameter in hb_codeblockGet*() function to 'int'
* merged codeblock execution context setting into one function
hb_vmDoBlock() and removed hb_codeblockEvaluate()
+ added new internal function hb_vmEval()
* harbour/src/vm/arrays.c
% use hb_vmEval()
* harbour/src/macro/macrolex.c
* added missing const to maro text declaration
* harbour/tests/speedtst.prg
! fixed to work with CLIP and xHarbour after we changed
SECONDSCPU() to HB_SECONDSCPU() - all these compilers and FlagShip
have SECONDSCPU() function
* src/rtl/fstemp.c
! Using hb_fsTempDir() in HB_FTEMPCREATEEX() instead of
old solution. This should fix it for some non-*nix
platforms where *nix specific TEMPDIR envvar was used
to determine temp directory.
* contrib/hbwin/Makefile
* include/Makefile
* src/rtl/Makefile
- contrib/hbwin/hbdyn.ch
+ include/hbdyn.ch
- contrib/hbwin/hbdyn.c
+ src/rtl/hbdyn.c
- contrib/hbwin/win_dllc.c
+ src/rtl/hbdynhb.c
- contrib/hbwin/tests/testdll.c
+ tests/testdyn.c
- contrib/hbwin/tests/testdll.prg
+ tests/testdyn.prg
- contrib/hbwin/tests/testdll1.prg
+ tests/testdyn1.prg
- contrib/hbwin/hbdyn.h
* include/hbapi.h
* Moved dynamic library call related functions to
core (RTL).
* Windows specific test code (currently all) guarded
for platform.
* Changed default calling convention to cdecl.
Tests adaptd accordingly.
* Terminology change: 'dll' -> 'dynamic library'
; HB_DYNCALL() is now part of core Harbour, and it's
platform independent. It's platform (ABI) dependent though,
and currently x64 and x86/stdcall/syscall/cdecl
is supported and these were tested (except OS/2 syscall).
* contrib/hbwin/hbwin.h
* contrib/hbwin/win_misc.c
* contrib/hbwin/legacycd.c
* Low level hbwin_getprocaddress() function moved
to legacy file and made static.
* contrib/xpp/Makefile
* contrib/xpp/dllx.c
* contrib/xpp/xpp.hbc
+ Enabled DLL*() functions for all platforms.
- Deleted dependence on hbwin library.
* contrib/xpp/tests/testdll.prg
* Windows specific parts (currently the whole test) guarded
for platform.
* contrib/hbct/Makefile
- contrib/hbct/diskhb.prg
* contrib/hbct/disk.c
* contrib/xhb/Makefile
+ contrib/xhb/diskhb.prg
* GETVOLINFO() moved from hbct to xhb.
* ChangeLog
* Marked some TODO/TOFIX items as DONE.
* harbour/include/hbvm.h
* harbour/src/vm/hvm.c
+ added new C function hb_vmFindFuncSym() which looks for function with
given name registered in HVM by dynamically loaded library. It looks
for public function and if public function cannot be located it tries
to find first static function which has requested name.
* harbour/include/hbapi.h
* harbour/src/vm/dynlibhb.c
+ added new C functions to manage dynamic libraries:
PHB_ITEM hb_libLoad( PHB_ITEM pLibName, PHB_ITEM pArgs );
HB_BOOL hb_libFree( PHB_ITEM pDynLib );
void * hb_libHandle( PHB_ITEM pDynLib );
void * hb_libSymAddr( PHB_ITEM pDynLib, const char * pszSymbol );
* harbour/include/hbextern.ch
* harbour/src/vm/dynlibhb.c
- removed HB_LIBDO() PRG function. If someone used it then please
use DO() instead
+ added new PRG function:
HB_LIBGETFUNSYM( <pLibHandle>, <cFuncName> ) -> <sFuncSym> | NIL
It works in similar way to HB_HRBGETFUNSYM() but it looks for
PRG function in given library. It tries to find public function
and if such function does not exists it looks for first static one.
<pLibHandle> is library handle returned by HB_LIBLOAD()
<cFuncName> is PRG function name.
<sFuncSym> is symbol of located function
If function can be found HB_LIBGETFUNSYM() returns NIL.
Warning: this function returns only symbols for functions registered
in HVM when library was loaded. It will not return symbols
for functions written in C and not explicitly registered
using own symbol table.
* harbour/src/pp/Makefile
* harbour/src/pp/hbpp.c
! fixed compilation with HB_DYNLIB macro
- harbour/src/vm/maindll.c
- removed unused dummy file
* harbour/src/vm/Makefile
* harbour/include/hbapi.h
+ harbour/src/vm/procaddr.c
+ added hb_vmProcAddress() function
* harbour/include/hbdefs.h
+ added HB_EXPORT_ATTR and HB_IMPORT_ATTR macros - they are always
defined regardless of HB_DYNLIB macro state
* harbour/src/vm/maindllh/Makefile
* disabled HB_DYNLIB
* harbour/src/vm/maindllp/Makefile
+ harbour/src/vm/maindllp/dllpcode.c
+ added new import library for PCODE DLLs. It contains wrappers for
hb_vmProcessSymbols() and hb_vmExecute() implemented in a way
which creates minimal speed overhead.
+ added error reporting (MessageBox()) when redirected functions
cannot be found.
+ added hb_dllGetProcAddress() C function
* harbour/include/hbtypes.h
- harbour/src/vm/maindllp.c
+ harbour/src/vm/maindllp/dllext.c
* moved old wrappers to some of extended and array API functions
into separate file
* updated to use hb_dllGetProcAddress()
- removed functions which should not be used by user code
% cleaned, optimized and added error reporting to function wrappers.
I do not know who chose exported functions but it looks like a
quite random set which should be extended for real functionality.
If someone is interested then he can do that. I updated this file
only for backward compatibility.
Above modifications allows to use PCODE DLLs with any application
also static ones using Harbour compiled without exported symbols.
It's enough to link it with this function:
HB_EXPORT_ATTR PHB_FUNC dll_hb_vmProcAddress( const char * szFuncName )
{
return hb_vmProcAddress( szFuncName );
}
The official form of including above function to final binaries is not
defined yet.
* src/vm/runner.c
* src/vm/garbage.c
* src/vm/classes.c
* src/rtl/cdpapi.c
* src/rtl/cdpapihb.c
* src/rdd/dbcmd.c
* include/hbapicdp.h
* include/hbapiitm.h
* include/hbextern.ch
* include/hbdefs.h
* include/hbsetup.h
* include/hbapi.h
- Deleted code guarded with (previously disabled) HB_LEGACY_LEVEL2
* include/rdd.api
* include/clipdefs.h
+ Permanently enabled HB_LEGACY_LEVEL2 related changes.
* contrib/xhb/bkgtsks.c
- Deleted HB_OS_WIN_USED. It wasn't used.
* include/hbapi.h
* src/vm/cmdarg.c
* hb_winmainArgGet() changed to not use Windows types.
This function is declared in hbapi.h and this header
shouldn't depend on windows.h.
* include/hbwince.h
* include/hbsetup.h
* HB_OS_HAS_DRIVE_LETTER is now configured in central
place (hbsetup.h) for WinCE platform also.
* include/hbwince.h
* include/hbdefs.h
* Windows (CE and not-CE) specific declarations moved from
hbwince.h to hbdefs.h.
* include/hbdefs.h
% hbwince.h inclusion now better guarded to not include it
for non WinCE platforms.
+ HB_OS_WIN_USED macro will now autodetected by checking
whether windows.h was included before this header.
This is required for hbwince.h. I don't like it, since
hbapi.h still depends on windows.h for WinCE platform,
which still ties us to unnecessary windows.h inclusion
rules. Rather, hbwince.h should be included directly
by .c files when needed and when HB_OS_WIN_CE is defined.
After all this our little Windows API implementation
for compilers which need it.
* include/hbdefs.h
* include/hbwmain.c
+ hb_winmainArgInit() declaration moved to hbwmain.c, the
only place where this is used.
* Deleted HB_EXPORT from hb_winmainArgInit. Pls speak up if
this is wrong. It's possible to move this back to hbdefs.h,
but parameter types should be changed to ANSI ones.
* contrib/gtwvg/gtwvg.c
* contrib/gtwvg/gtwvg.h
* contrib/gtwvg/wvggui.c
* contrib/gtwvg/wvgcuig.c
* contrib/gtwvg/wvggui.h
* contrib/gtwvg/wvgwin.c
* contrib/gtwvg/wvgutils.c
* contrib/gtwvg/wvgcore.c
* contrib/gtwvg/wvgwing.c
- Deleted HB_OS_WIN_USED. Now it should work without it.
windows.h was already included in non-official method, so
it's now okay also.
* include/hbapi.h
* src/vm/memvars.c
* ULONG -> HB_SIZE where applicable
* int -> HB_ISIZ where it was used for size
* src/vm/macro.c
! LONG -> long for date/time.
* include/hbchksum.h
* src/rtl/hbadler.c
* src/rtl/hbcrc.c
* src/rtl/hbi18n1.c
* contrib/hbmzip/hbmzip.c
* ULONG -> HB_U32 for crc32 and adler32
* ULONG -> HB_U16 for crc16
(the crc table was also changed to HB_U16, pls speak up if this
may cause less-optimal performance than previous state.)
* int -> HB_ISIZ where it was used for size (in adler loop)
* include/hbapi.h
* HB_VMHANDLE is now mapped to 'unsigned long' instead of ULONG
* contrib/hbwin/win_bmp.c
- Deleted no more necessary cast.
* harbour/include/hbapifs.h
* harbour/src/rtl/filebuf.c
* harbour/contrib/hbmemio/memio.c
* harbour/contrib/hbnetio/netiocli.c
+ added new method:
void Flush( PHB_FILE pFile, HB_BOOL fDirty );
to replaceable RDD IO structure (HB_FILE)
+ added new function:
void hb_fileFlush( PHB_FILE pFile, HB_BOOL fDirty );
* harbour/src/rdd/dbfntx/dbfntx1.c
* harbour/src/rdd/dbfnsx/dbfnsx1.c
* harbour/src/rdd/dbfcdx/dbfcdx1.c
* harbour/src/rdd/dbffpt/dbffpt1.c
* use hb_fileFlush()
* harbour/src/vm/hvm.c
* harbour/include/hbxvm.h
! fixed hb_xvm{Local,Static,Module}Name() to use 'const char *'
instead of 'char *' - modifications by Xavi (jarabal)
* harbour/include/hbapi.h
* harbour/include/hbxvm.h
* harbour/include/hbmacro.h
* harbour/include/hbcompdf.h
* harbour/src/vm/hvm.c
* harbour/src/vm/macro.c
* harbour/src/vm/memvars.c
* replaced some 'BYTE' types with 'unsigned char' or 'int' types
* cleanup some other casting and types to reduce conversions
between function calls
* harbour/src/common/expropt1.c
; updated comments
* harbour/include/hbpp.h
* harbour/include/hbexprop.h
* harbour/include/hbexpra.c
* harbour/include/hbexprb.c
* eliminated HB_EXPR_PCODE?() macros
! fixed potential GPF trap during compilation of _GET_() functions
which can be exploited by strange code using some special expressions
as get variable.
TODO: eliminate hb_compExprClone() used in hb_compExprSetGetBlock(),
our optimization module does not care about shared expressions
so it can be source of serious problems in the future if someone
use this functions for non optimized expression which will be
reduced later.
* emulate clipper behavior for codeblock optimizations and do
not optimize all codeblocks if -kc switch is used and codeblocks
is inside non optimized part of code like (Clipper has such
places)
% simplified and optimized some functions like hb_compExprReduceList()
* harbour/include/hbapi.h
* harbour/src/common/hbver.c
+ added BOOL hb_iswin9x( void ) C function
* harbour/src/rtl/version.c
+ added HB_OSISWIN9X() PRG function
* harbour/src/rtl/gttone.c
% simplified the code using hb_iswin9x() function
TODO: Check if WinCE support WinNT file IO functions and if yes then
replace in src/rtl/filesys.c 'if( hb_iswinnt() )' with
'if( !hb_iswin9x() )'
* harbour/contrib/hbwin/win_tprn.prg
* harbour/contrib/hbwin/win_prn1.c
+ added ::AskProperties in WIN_PRN class
If it is assigned .t. prior to calling ::Create(), a DocumentProperties
dialog is displayed. By Budyanto Dj. borrowed from xHarbour.
NOTE: this modification does not contain win9x hack present in
xHarbour. Please make tests and update this code if necessary
* harbour/include/hbapi.h
* harbour/src/vm/hashes.c
+ added new function hb_hashGetCItemPtr() which accepts ASCIIZ string
as index.
* harbour/contrib/hbnetio/netiosrv.c
+ added support for using HASH arrays as RPC filter.
Such hash array should be indexed by function/procedure name set of
codeblocks or function references or even objects which understand
EVAL method.
Please remember that function names passed from client side are case
sensitive so if you do not need it then please disable case matching
in the hash array, i.e. using HB_HSETCASEMATCH( hValue, .F. ).
* renamed NETIO_RPCFUNC() to NETIO_RPCFILTER() it's better name now
because we added support for using hash arrays as RPC filters:
NETIO_RPCFILTER( <pConnectionSocket>,
<sFuncSym> | <hValue> | NIL ) -> NIL
* harbour/contrib/hbnetio/netiomt.prg
+ added support for setting RPC filter in NETIO_MTSERVER() using its
4-th parameter:
NETIO_MTSERVER( [<nPort>], [<cIfAddr>], [<cRootDir>],
[<lRPC> | <sFuncSym> | <hValue>],
[<cPasswd>], [<nCompressionLevel>], [<nStrategy>] )
-> <pListenSocket>
* harbour/contrib/hbclipsm/environ.c
! fixed GPF in FILEDRIVE() function on platforms which do not support
drive letters or when path does not contain drive.
% small optimization in FILEPATH(), FILEBASE(), FILEEXT(), FILEDRIVE()
* harbour/include/hbapi.h
* harbour/src/common/hbprintf.c
+ added new function 'int hb_printf_params( const char * format )' which
returns number of parameters necessary for format string
* harbour/src/common/hbtrace.c
* added protection against recursive calls when number of parameters
used by HB_TRACE message us bigger then 16 and fm.c module was compiled
with HB_TR_DEBUG macro
% use the same number of characters for unicode and byte string buffers
% use common memory area (union) for unicode and byte messages to reduce
C stack usage
Please test these modifications in real MS-Windows systems.
* src/vm/fm.c
* include/hbapi.h
+ Added hb_xtraced(). Please check it might be wrong.
* src/common/hbtrace.c
- Deleted hack to disable winout to avoid recursive calls.
+ Added TOFIX to avoid recursive calls with some clever
detection on error case (hb_xtracd() && no_of_formatt_strings > 16)
I didn't implement it, pls do so if interested.
! Fixed MultiByteToWideChar sizeof() to HB_SIZEOFARRAY().
* harbour/include/Makefile
* harbour/include/hbmath.h
+ harbour/include/hbmather.h
* harbour/include/hbsetup.h
* harbour/include/hbapi.h
* moved math error handler definitions and settings separate header file
* moved hb_random_num() declaration from hbmath.h to hbapi.h
After above modification hbmath file should be use only by code which
wants to use math functions declared usually in math.h
+ harbour/include/hbfloat.h
+ added header file with test macros for floating point numbers
this file should be included before any other files
* harbour/src/vm/hvmall.c
* harbour/src/vm/itemapi.c
* harbour/src/common/hbprintf.c
* harbour/src/rtl/math.c
* use new macros from hbfloat.h
* harbour/src/rtl/math.c
+ include "hbmather.h"
* harbour/src/rtl/hbrandom.c
* harbour/src/rdd/dbf1.c
* harbour/contrib/xhb/hboutdbg.c
- removed not longer necessary include "hbmath.h"
* harbour/contrib/hbct/ctmath.h
- do not include <float.h> and <limits.h>
* harbour/contrib/hbct/ct.h
- do not include "hbmath.h" and "ctmath.h"
* harbour/contrib/hbct/ctmath.c
* harbour/contrib/hbct/exponent.c
* harbour/contrib/hbct/ctc.c
+ include "ctmath.h"
* harbour/contrib/hbct/trig.c
* harbour/contrib/hbct/finan.c
* harbour/contrib/hbct/ctmath2.c
+ include "ctmath.h"
+ include "hbmather.h"
* harbour/contrib/hbct/num1.c
+ include "ctmath.h"
+ include <float.h>
* harbour/include/hbinit.h
* harbour/src/rtl/hbsocket.c
* added patches from Tamas - thanks
* harbour/bin/hb-func.sh
* harbour/harbour.spec
+ create /etc/ld.so.conf.d/harbour.conf with Harbour shared lib directory
if /etc/ld.so.conf.d directory exists and user has sufficient write
permission or install package is created.
This modification allows to install Harbour anywhere and in modern
distros using /etc/ld.so.conf.d/ harbour shared libraries will be
always available for all programs
[TOMERGE 2.0]
* harbour/include/hbapi.h
* harbour/src/vm/garbage.c
- removed function hb_gcRefDec()
* functions hb_gcRefInc() and hb_gcRefFree() moved to public API
After recent modifications in GC which introduced user defined
mark functions it's reasonable to make these function public to
extend functionality and give GC full interface to user defined
blocks.
* harbour/include/hbgtcore.h
* harbour/include/hbapigt.h
* moved declaration of hb_gtSetDefault() from hbgtcore.h to hbapigt.h
* harbour/include/hbapi.h
* harbour/src/vm/hvm.c
+ added new function hb_vmSetDefaultGT()
* harbour/bin/hb-func.sh
* harbour/utils/hbmk2/hbmk2.prg
* use hb_vmSetDefaultGT() to set default GT
* removed extern declarations for functions defined in hbapi.h
* harbour/src/vm/dynlibhb.c
+ added support for HB_LIBLOAD()/HB_LIBFREE() in DJGPP 2.04 builds
* harbour/config/global.mk
* use 8.3 names for harbour dynamic libraries in all DOS builds
* harbour/config/dos/djgpp.mk
+ added support for dynamic libraries (DXE) in DJGPP builds.
DXE is sth similar to DLL in Windows and can be used with
DJGPP 2.04. I had to make some modifications in DXE header
files to make it working so it will not work in default DJGPP
installation. I'll document these modifications in the future.
* harbour/config/dos/watcom.mk
* enable creating of harbour dynamic libraries only when HB_BUILD_DLL
is explictly set by user to 'yes'. In DOS DJGPP and OpenWatcom builds
DLLs support is not functional yet.
* harbour/config/dyn.mk
* added an option to create harbour dynamic libraries from static
ones instead of .o|.obj files. It's necessary for DXE3GEN which
internally calls LD which has some limited on maximum size of passed
parameters.
TODO: make HB_DYN_LIBS definition common for dyn.mk and lib.mk
* src/rtl/gtwin/gtwin.c
* Using HB_SIZEOFARRAY().
* include/hbapi.h
* Typo in comment.
* ChangeLog
+ Added missing item to prev.
* contrib/hbwin/tests/testmapi.prg
! Fixed missing SVN props.
! Added missing SVN ID.
* Formatting.
; TOFIX: This example expects arrays and logical value from command line,
so it won't work.
* harbour/include/hbapi.h
* harbour/include/hbvm.h
* harbour/include/hbvmpub.h
* harbour/include/hbstack.h
* harbour/src/vm/hvm.c
* harbour/src/vm/estack.c
* harbour/src/vm/fm.c
* harbour/src/vm/garbage.c
+ added new function hb_xclean() executed by GC just before resuming
suspended threads - it can be used by memory manager to clean
internal structures and release unused memory to OS.
% release unused memory to OS in hb_xclean() when DLMALLOC is used
% release unused memory in all mspaces to OS in hb_xclean() when
HB_FM_DLMT_ALLOC is used
% release unused memory in mspace when last thread detach it
% balance used mspaces between threads in hb_xclean() when
HB_FM_DLMT_ALLOC is used
* include/hbapi.h
* Changed HB_ERRCODE to be 'insigned int' (was USHORT).
; You'll need to rebuild all sources.
* utils/hbmk2/hbmk2.prg
% Turned off line numbers (for hbmk2 itself).
* INSTALL
* Minor formatting.
* harbour/include/hbapi.h
* harbour/src/vm/garbage.c
* added emulation for hb_gcAlloc() function covered by HB_LEGACY_LEVEL2
It will be removed in the future but now it gives a time for 3-rd party
code developers to updated existing code and switch to hb_gcAllocate()
* harbour/contrib/hbwin/hbwinole.h
* harbour/contrib/hbwin/olecore.c
+ added hb_oleItemGetCallBack() and hb_oleItemSetCallBack()
functions and support for user defined items bound with
OLE GC pointer item
* harbour/contrib/hbwin/axcore.c
* bound callback function with OLE item so it will be automatically
released with OLE object
* harbour/contrib/hbwin/tests/testax.prg
! destroy window
* enabled destructor
So far MS-Windows users haven't defined expected behavior for OLE code
so I took my own arbitrary decision and bound callback with OLE GC item.
When last copy of this item is cleared then callback is unregistered
and freed. It means that it can happen before AX window is closed.
If you prefer different behavior then please clearly define what
you need and I can try to change existing code.
Now testax.prg should cleanly execute without any GPF traps and
resource leaks.
* harbour/src/rdd/dbfnsx/dbfnsx1.c
! fixed bug reported by Jaroslav Janik (many thanks) - if index FOR
expression excluded all records from non empty table then root page
was not initialized and DBFNSX generated corruption RTE.
* harbour/utils/hbi18n/hbi18n.prg
* set default GT to CGI
* harbour/src/common/hbgete.c
! fixed memory leak in non UNICODE Windows hb_getenv_buffer()
! add C stack buffers to eliminate memory allocation in UNICODE
Windows hb_getenv_buffer() - they are used if envvar name and
passed buffer are not too large. It fixes HB_FM_STATISTICS
Windows builds.
* harbour/contrib/hbwin/wapi_winuser.c
+ added WAPI_DESTROYWINDOW function
* harbour/contrib/xhb/traceprg.prg
* harbour/contrib/xhb/hbcompat.ch
! fixed typo in TraceLog() condition - was always disabled
+ added emulation for xHarbour Set( _SET_TRACE* [, <params,...> ] )
settings
* harbour/src/vm/hvmall.c
! define _GNU_SOURCE to fix compilation with HB_FM_DL_ALLOC in Linux
builds
* harbour/include/hbdefs.h
* declare HB_FOFFSET as LONG instead of LONGLONG on platforms where
LONG is 64bit integer to be compatible with C RTL file API
* harbour/src/vm/maindllh.c
* harbour/src/vm/maindllp.c
* harbour/contrib/hbct/ctstr.c
! casting in HB_TRACE() massages
* harbour/include/hbapi.h
* harbour/include/hbapiitm.h
* harbour/src/vm/arrays.c
* harbour/src/vm/hashes.c
* harbour/src/vm/itemapi.c
+ added hb_arrayCloneTo(), hb_hashCloneTo(), hb_itemCloneTo()
* harbour/src/vm/arrayshb.c
* harbour/src/vm/classes.c
* harbour/src/vm/hashes.c
* harbour/src/vm/hashfunc.c
* harbour/src/vm/hvm.c
% use hb_*CloneTo() instead of hb_*Clone()
* harbour/include/hbapi.h
* harbour/src/vm/garbage.c
- removed hb_gcRegisterSweep() function and support for user defined
sweep mark functions in GC blocks
- removed hb_gcAlloc() function
+ added new function hb_gcAllocate() which work in similar way to removed
hb_gcAlloc() function but it accepts as second parameter HB_GC_FUNCS
structure instead of HB_GARBAGE_FUNC_PTR and returned GC blocks are
locked so programmer does not have to worry that they can be removed
by GC.
+ added new internal function hb_gcAllocRaw() which works like
hb_gcAllocate() but returned GC blocks are not locked. They can
be used only in HVM in places well known that cannot activate
automatic GC scan. It should not be used by 3-rd party code.
* harbour/include/hbapi.h
* harbour/include/hbapiitm.h
* harbour/src/vm/extend.c
* harbour/src/vm/itemapi.c
* modified hb_parptrGC(), hb_parvptrGC(), hb_arrayGetPtrGC(),
hb_itemGetPtrGC() functions to use HB_GC_FUNCS structure instead
of HB_GARBAGE_FUNC_PTR
* modified hb_itemPutPtrGC() and indirectly related functions like
hb_arraySetPtrGC() or hb_stor[v]ptrGC() to automatically unlock
passed GC block just after attaching to known HVM item.
* harbour/include/hbregex.h
* harbour/src/rtl/hbregexc.c
* declare GC block detractor as static function
+ added hb_regexIs() function
* updated to work with new GC API
* removed unnecessary in new GC API hb_gcLock() call - GC blocks
allocated by hb_gcAllocate() are already locked and they mustn't
be locked explicitly by programmer (until he does not exactly knows
what he does ;))
* harbour/src/rtl/hbregex.c
* use hb_regexIs() instead of using regex GC destructor
* removed unnecessary in new GC API hb_gcUnlock() call - GC blocks
stored in HB_IT_POINTER item are automatically unlocked
* harbour/src/rtl/hbinet.c
* harbour/contrib/hbcurl/hbcurl.c
* updated to work with new GC API
% unlock items storing callback codeblocks and use GC mark functions
to mark them as used in GC passes
* harbour/src/pp/pplib.c
* harbour/src/vm/runner.c
* harbour/src/vm/codebloc.c
* harbour/src/vm/hashes.c
* harbour/src/vm/hvm.c
* harbour/src/vm/arrays.c
* harbour/src/vm/thread.c
* harbour/src/vm/dynlibhb.c
* harbour/src/rtl/hbzlibgz.c
* harbour/src/rtl/hbregex.c
* harbour/src/rtl/hbregexc.c
* harbour/src/rtl/hbgtcore.c
* harbour/src/rtl/hbi18n1.c
* harbour/src/rdd/wacore.c
* harbour/contrib/hbsqlit3/hbsqlit3.c
* harbour/contrib/hbnetio/netiosrv.c
* harbour/contrib/hbmzip/hbmzip.c
* harbour/contrib/hbhpdf/harupdf.c
* harbour/contrib/hbwin/olecore.c
* harbour/contrib/hbwin/win_prn1.c
* harbour/contrib/hbwin/win_dll.c
* updated code which was using hb_gcAlloc() to work with new GC API.
* harbour/contrib/hbwin/axcore.c
* updated syntax description
TODO: update contrib code: hbqt, hbssl, ... to work with new GC API.
I would like to ask authors of above libraries to do it.
TODO: defined when and how we should free AX control and user callback
handler and update AX code to respect new definition
* harbour/include/hbapi.h
+ added hb_xgrabz() and hb_xmemdup() macros
* harbour/include/hbapicdp.h
* harbour/source/rtl/cdpapi.c
+ added new functions which can be used in translations changing the
size of trnaslated strings:
hb_cdpDup(), hb_cdpnDup(), hb_cdpnDup2(), hb_cdpnDup3(),
hb_cdpnDupLen(), hb_cdpnDup2Len()
Now hb_cdp[n]Translate() functions are depreciated.
+ added pseduto codepage "UTF8" which can be used in trnaslations only
+ added new function hb_cdpFindExt() which allows to chose pseudo CPs
* harbour/include/hbapi.h
* harbour/include/hbset.h
* harbour/source/vm/set.c
* harbour/source/nortl/nortl.c
- removed old functions: hb_osEncode() and hb_osDecode() with low level
code which was using static char to char translation table
+ add new functions hb_osEncodeCP() and hb_osDecodeCP() which can make
translations changing the size of translated strings.
Warning all parameters have to be initialized.
Passing NULL in second parameter means that the 1-st is dynamically
allocated and can be used as buffer and reallocated if necessary.
if 2-nd parameter is not NULL then the 1-st one is used as const value.
The size of allocated buffer can be passed by reference in 3-rd
parameter and this value is updated on reallocation.
If buffer is two small then new bigger one is allocated and old one
freed.
* harbour/source/vm/set.c
+ added support for UTF8 translations in _SET_OSCODEPAGE
* harbour/source/vm/cmdarg.c
* harbour/source/common/hbffind.c
* harbour/source/rtl/filesys.c
* harbour/source/rtl/philes.c
* harbour/source/rtl/gete.c
* harbour/source/rtl/net.c
* harbour/source/rtl/hbproces.c
* harbour/source/rtl/hbrunfun.c
* harbour/source/rtl/run.c
* harbour/contrib/hbwin/win_misc.c
* harbour/contrib/hbwin/wapi_shellapi.c
* harbour/contrib/hbwin/wapi_winbase.c
* use new hb_osEncodeCP()/hb_osDecodeCP() functions
* harbour/source/rtl/hbi18n1.c
* harbour/source/rtl/gtxwc/gtxwc.c
* harbour/source/rtl/gtpca/gtpca.c
* replaced depreciated hb_cdp[n]Translate() functions with new
hb_cdp[n]Dup*()
* harbour/source/rtl/gtstd/gtstd.c
* harbour/source/rtl/gtcgi/gtcgi.c
* harbour/source/rtl/hbgtcore.c
* replaced depreciated hb_cdp[n]Translate() functions with new
hb_cdp[n]Dup*()
+ added support for UTF8 translations set by hb_setDispCP() and
hb_setTermCP() functions
* harbour/source/rdd/delim1.c
* harbour/source/rdd/sdf1.c
* harbour/source/rdd/dbf1.c
* harbour/source/rdd/dbffpt/dbffpt1.c
* harbour/source/rdd/dbfnsx/dbfnsx1.c
* harbour/source/rdd/dbfcdx/dbfcdx1.c
* harbour/source/rdd/dbfntx/dbfntx1.c
* replaced depreciated hb_cdp[n]Translate() functions with new
hb_cdp[n]Dup*()
+ added support for CP translations which can change the size of
translated strings
! disabled memo field translations for fields marked as binary
+ added support for UTF8 translations.
Using UTF8 as CP disables any national sorting in indexes.
Warning: please remember that normal character fields in tables have
fixed size and translation to UTF8 may increase the string
and cut results.
* harbour/source/rdd/dbf1.c
! fixed GPF in dbCreate() with empty struct table