* include/hbdefs.h
* Changed HB_SIZE to ULONG. Added TOFIX to later change it
to 'long'. With its current setup it's possible to gradually
change 'ULONG' usages to 'HB_SIZE' when used as string/array
length ot index. This can be a gradual process.
* include/hbdefs.h
+ Added HB_MAX[U]INT as new name for HB_[U]LONG.
+ Added HB_[U]LONG to new type list with TOFIX note.
* Changed HB_ATTR to not rely on Windows type.
- Deleted hb[Type] style types from planning.
* config/detect.mk
- Disabled OpenSSL detection for bcc.
For some reason it's building with errors now.
I can't figure what change caused this as it was building
fine a month ago. It's not the hbssl source code, openssl
sources are the same, I have no time to figure it out.
Anyway it wasn't working with bcc at link time anyway.
* include/hbdefs.h
+ Added new planned types. These are meant to replace previous
proposition with the format 'hb<Type>'. New ones use usual
'HB_<TYPE>' format. Also added HB_TRUE and HB_FALSE.
These new names don't look alien at all in code, so hopefully
we can go into the transition with more courage. As a plus,
some of the HB_TYPE format types are already implemented and
used (HB_WCHAR, HB_LONG, HB_ULONG, etc).
A new important type is HB_SIZE, which I hope will replace
ULONG for string and array indices.
* Changed HB_CHAR to be declared as 'char' instead of 'BYTE'.
(this type was added long ago, but is not yet used anywhere
in code)
* Changed HB_COLOR to be declared as 'int' instead of 'BYTE'.
(this type was added long ago, but is not yet used anywhere
in code, since then we've settled to 'int' to represent
colors. Pbly we should move to use this abstract type instead
of int in code.)
; I left hb<Type> code as of yet, but if there is no objection,
I'd like to remove them.
; Here are the new types:
HB_TRUE
HB_FALSE
HB_BOOL
HB_BYTE
HB_CHAR
HB_ULONG
HB_LONG
HB_UINT
HB_SHORT
HB_USHORT
HB_LONGLONG
HB_ULONGLONG
HB_I8
HB_U8
HB_I16 ( HB_I16_MIN, HB_I16_MAX )
HB_U16 ( HB_U16_MAX )
HB_I32 ( HB_I32_MIN, HB_I32_MAX )
HB_U32 ( HB_U32_MAX )
HB_I64 ( HB_I64_MIN, HB_I64_MAX )
HB_U64 ( HB_U64_MAX )
HB_SCHAR
HB_UCHAR
HB_SIZE
HB_DOUBLE
; QUESTION: Do we really need 3 different flavors to denote char/byte?
HB_BYTE - HB_UCHAR - HB_U8
HB_CHAR - HB_SCHAR - HB_I8
If not, we should decide which ones to keep.
If yes, it would be nice to have some guide when to use which.
* utils/hbmk2/hbmk2.prg
+ Added plans (TODO) for next gen compiler autodetection.
This will surpass currently implemented autodetection in
build system. The basic feature added is detection of all
compilers supported by Harbour installation, so it's not
possible to select one which is not installed, plus more
feedback can be given to user. It also cleans embedded vs
in-PATH compilers and gives an easier way to prioritize
found compilers. This is definitely scheduled after
2.0.0 release, and when I have (more) time.
* contrib/hbqt/generator/hbqtgen.prg
* contrib/hbqt/hbqt.h
* contrib/hbqt/hbqt_destruct.cpp
* contrib/hbqt/hbqt_slots.cpp
* contrib/hbqt/hbqt_slots.h
* contrib/hbqt/moc_slots.cpp
* contrib/hbxbp/tests/demoxbp.prg
* contrib/hbxbp/xbpbrowse.prg
* contrib/hbxbp/xbpdialog.prg
* contrib/hbxbp/xbpgeneric.prg
* contrib/hbxbp/xbpmenubar.prg
* contrib/hbxbp/xbpwindow.prg
* contrib/qtgui/QTableView.cpp
* contrib/qtgui/TQTableView.prg
! Some more debug information included.
Please note that the build may be broken, so bear with me for a
couple of days. Lorenzo, you can continue with experiments.
* harbour/contrib/rddads/ads1.c
! In APPEND metohd generate RT error EG_APPENDLOCK only if ACE returns
1024 error code (Append Lock Failed). In all other cases generate
EG_CORRUPTION RTE.
This modifications allows to early detect some serious problems like
index corruptions in Mindaugas example with long keys in ADSCDX.
Warning! Before ADS RDD generated EG_APPENDLOCK for each errors
returned by AdsAppendRecord() and they were caught by default error
handler (ERRORSYS) and silently converted to NetErr().
Now only for 1024 ACE error which is real append lock error
EG_APPENDLOCK is generated and all other errors will not be silently
ignored so it's also possible that this modification will exploit
some errors in concurrent accessed which are not reported by ADS/ACE
as 1024 and maybe we will have to report them as EG_APPENDLOCK too.
In such case please send information about such error codes here.
* harbour/src/rdd/dbfcdx/dbfcdx1.c
% added small protection against code which may want to create
degenerated index tree using very large keys (over 158 bytes length)
+ w64-make.exe
+ Added win64 build of GNU Make 3.81.90-CVS-20090901.
Experimental. On 64-bit Windows systems it's generally
recommended to use this version, but please be aware of
the experimental nature of this build yet. There are
some pending patches in GNU Make bug tracker, plus latest
CVS is broken so I used the latest good one.
* INSTALL
+ Added NOTE for Borland C++ users how to setup their
compiler. This is repetition of Borland readme content
which seemingly nobody reads and do this day many users
get wrong. I'm not sure if these same users will read
INSTALL, but let's give it a try.
* ChangeLog
! Fixed my timezone since last weekend.
* package/winuni/RELNOTES
+ Provisions for next version: MinGW 4.4.1 updated documented.
Now at TDM-2, fixing some seriously looking performance
problem. (tdragon.net distro)
* INSTALL
* Minor fix to UPX supported platforms.
* contrib/hbmisc/Makefile
+ contrib/hbmisc/ffind.c
+ Added direct file find API from my own function collection:
FILEFINDFIRST( <cFileNameMask>, @<ffindinfo>[, <nAttr> ] ) -> <lFound>
FILEFINDNEXT( <ffindinfo> ) -> <lFound>
FILEFINDNAME( <ffindinfo> ) -> <cFileName> (without drive/dir)
FILEFINDATTR( <ffindinfo> ) -> <nAttr>
FILEFINDSIZE( <ffindinfo> ) -> <nSize>
FILEFINDDATE( <ffindinfo> ) -> <dDate>
FILEFINDTIME( <ffindinfo> ) -> <cTime> (as "HH:MM:SS")
It's an alternative to DIRECTORY()/FILE() functions.
; NOTE: To release the file find handle on some platforms
(like Windows), and allow deletion of the dir we've
been scanning, <ffindinfo> should go out of scope or
be explicitly release by freeing <ffindinfo> variable.
To make this easy, some may want to add:
#xtranslate FILEFINDCLOSE( <f> ) => \( <f> := NIL \)
#xtranslate FILEFINDCLOSE( @<f> ) => \( <f> := NIL \)
; NOTE: Could be extended to return new timestamp format.
* contrib/rddads/adsfunc.c
+ Added lAlive := AdsIsConnectionAlive( hConnection ) function.
Borrowed from Augusto Infante / xhb.
Three small fixes applied.
* harbour/src/common/hbgete.c
* harbour/src/common/hbffind.c
* harbour/src/common/hbfsapi.c
* harbour/src/rtl/fstemp.c
* harbour/src/rtl/filesys.c
* harbour/src/rtl/diskspac.c
* harbour/src/rtl/disksphb.c
* harbour/src/rtl/net.c
! fixed memory leak reported by Pritpal
* cleanup some UNICODE conversions in Windows builds (mostly resolved
some macros when UNICODE macro is also explicitly used and cleaned
some buffers length passed to windows functions.
* removed unnecessary casting - if it's not necessary for some strange
reasons never cast strings to LP[C][TW]STR calling windows functions.
Such casting does not make any conversions but only hides potential
bugs.
* harbour/contrib/hbwin/axcore.c
* pacified warning
* harbour/doc/xhb-diff.txt
+ added information about Harbour and xHarbour versions described by
above text - thanks to Chen for suggestion
* small update for HBNETIO and HBMEMIO
+ harbour/doc/xhb-diff.txt
+ added text which describes most important differences between Harbour
and xHarbour with some references to Clipper and other compatible
compilers like xBase++, CLIP, FlagShip.
Many thanks to Viktor and Pritpal for updating this text.
* utils/hbmk2/hbmk2.prg
! Fixes to lib dependency detection code.
It should now work on darwin/bsd/hpux/beos gcc/clang/sunpro
platforms/compilers but obviously I didn't test them all
(only darwin/clang).
There was one typo hitting generic branch of lib detection
plus lib prefix was not taken into account at all there.
Probably on some platforms it would be better to implement
target specific lib searching algorithm to mimic actual
linker behaviour. Currently, differences are to be expected.
- Deleted gccomf from a win/wce only branch in LibExists().
* contrib/hbqt/hbqt_slots.cpp
* contrib/hbqt/hbqt_slots.h
* contrib/hbqt/moc_slots.cpp
* contrib/hbqt/qtcore/QAbstractItemModel.cpp
* contrib/hbqt/qtcore/TQAbstractItemModel.prg
* contrib/hbqt/qth/QAbstractItemModel.qth
* contrib/hbxbp/xbpbrowse.prg
* contrib/hbxbp/xbpdialog.prg
* contrib/hbxbp/xbpgeneric.prg
* contrib/hbxbp/xbphtmlviewer.prg
* contrib/hbxbp/xbplistbox.prg
* contrib/hbxbp/xbprtf.prg
* contrib/hbxbp/xbptabpage.prg
* contrib/hbxbp/xbptreeview.prg
* contrib/hbxbp/xbpwindow.prg
* contrib/hbxbp/tests/demoxbp.prg
! Fixes to release objects in proper order.
Now demoxbp.exe terminates fine. Also you can
open as many dialogs as you want. Closing next dialog
releases the memory belonging to Qt objects but still
I have to investigate why whole of thread memory is not
released. So I have kept debug code intact. Just play with
current code, may be you can pin-point where Xbp*classes
need more tweaks.
* harbour/src/rtl/gtxwc/gtxwc.c
* use XSetWMName() instead of XStoreName() to set window title
using UTF8 strings
* harbour/include/hbapigt.h
* always declare hb_gtIsGtRef() for C++ compiler
* contrib/hbwin/axcore.c
* Replaced duplicated constant with HB_SIZEOFARRAY() macro.
* utils/hbmk2/hbmk2.prg
+ C compiler autodetection will now make sure to skip compilers
where required Harbour core libraries aren't installed.
This autodetection is disabled when HB_LIB_INSTALL is set
manually and also when lib/<plat> dir is missing altogether,
assuming there is a single-compiler installation used in this
case (where such autodetection cannot work reliably).
When using -info option, a screen message is shown if
autodetected C compiler is skipped for above reason.
* harbour/contrib/xhb/xhbarr.c
+ added XHB_AINS(), XHB_ADEL() functions which accept negative indexes.
Warning I haven't replicated xHarbour bugs in AINS() so it's not
exactly the same. Sooner or later someone will fix AINS() code in
xHarbour CVS. This code illustrates the problem and also
incompatibilities with Clipper:
#ifdef __HARBOUR__
#ifndef __XHARBOUR__
#xtranslate adel(<x,...>) => xhb_adel(<x>)
#xtranslate ains(<x,...>) => xhb_ains(<x>)
#endif
#endif
proc main()
local a := { 100, 200, 300 }
? ; aeval( a, { |x| qout( x ) } )
adel( a, -1, .t. )
? ; aeval( a, { |x| qout( x ) } )
ains( a, -1, 400, .t. )
? ; aeval( a, { |x| qout( x ) } )
ains( a )
? ; aeval( a, { |x| qout( x ) } )
return
* 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.
* contrib/hbwin/tests/testdll.prg
* Minor.
* contrib/hbwin/win_dll.c
% Deleted cDLL structure member.
- Deleted __XHARBOUR__ guarded parts (related to C structure handling,
probably never tested, plus it didn't look something mature anyway)
; TOFIX: win64 .dll support, strangely testdll gives slightly
different results for BCC and MSVC builds (and MINGW
builds where it GPFs), also UNICODE isn't supported at all.
So I guess Harbour .dll handling would better be rewritten.
* harbour/src/vm/hashes.c
! use hb_gcMark() instead of hb_gcItemRef() to mark unlocked item
* harbour/src/vm/garbage.c
* moved hb_itemClear() from hb_gcGripDrop() to hb_gcGripRelease()
Now items are freed in the same way as any other GC blocks and
hb_gcGripDrop() is simple wrapper to hb_gcRefFree()
* harbour/src/vm/hvm.c
* harbour/src/vm/thread.c
! unlock item which stores thread return value to eliminate possible
memory leaks, i.e. when thread returns its own pointer item.
! unlock item which stores notify messages to eliminate possible
memory leaks, i.e. when mutex is used as notify value in its
own message queue.
* harbour/include/hbapigt.h
* harbour/include/hbgtcore.h
* harbour/src/rtl/hbgtcore.c
* harbour/src/vm/garbage.c
+ added new GT method MARK() executed by GC to mark all internall
GC blocks as used.
+ added hb_gtIsGtRef() internal function
! unlock internal GT items (pCargo, pNotifierBlock, pMutex) to
eliminate possible memory leaks, i.e. when pGT item is stored
in it's own cargo value or is accessed from notifier codeblock
* harbour/src/vm/garbage.c
! fixed hb_gcGripDrop() to work well with unlocked items and
items freed by GC
* harbour/tests/speedtst.prg
! typo in comment
* contrib/hbqt/generator/hbqtgen.prg
! Fixed to honor Przemek's changes pertaining "
LONG is 64bit integer and HB_LONG is declared as LONG not LONGLONG
* harbour/contrib/hbqt/qtcore/QLocale.cpp
* harbour/contrib/hbqt/qtcore/QByteArray.cpp
! fixed casting for 64bit builds - in all 64bit builds except Win64
LONG is 64bit integer and HB_LONG is declared as LONG not LONGLONG
* harbour/contrib/hbwin/win_dll.c
% minor optimization
* removed unnecessary casting
* src/vm/maindllp.c
! Using hb_getProcAddress() instead of GetProcAddress().
Idea submitted to the list, I didn't make any tests, so
review it and change it as needed.
* contrib/xhb/hbcompat.ch
+ Added HB_GTI_CLIPBOARDPAST related stuff.
* harbour/src/rtl/hbbffnc.c
+ added support for 3-rd parameter <lRaw> in hb_blowfishEncrypt() and
hb_blowfishDecrypt() functions. It disables ANSI X.923 padding but
encode passed string in 8bytes blocks. If last block in string is
smaller then it's padded to 8 bytes using chr(0) and information
about original string size is not attached to encrypted data.
During decoding only strings which are well padded (N*8 bytes) are
accepted and <lRaw> := .T. disables restoring original string size
encoded in encrypted string using ANSI X.923 standard so the size
of decrypted string is the same as original one.
* harbour/contrib/hbwin/axcore.c
! fixed wrongly initialized reference counter in AX control.
Now when AX Window is closed and all .prg references to OLE
are cleared pSink is released.