* src/rtl/filesys.c
! fixed FXO_TRUNCATE flag used without FXO_SHARELOCK in POSIX systems
* src/rtl/net.c
! typo in variable name
* src/vm/task.c
! variable scope
* src/compiler/compi18n.c
* minor variable type update
* ChangeLog.txt
! formatting
* src/rtl/Makefile
* src/rtl/net.c
+ src/rtl/netusr.c
* moved hb_UserName() to separate file. It uses internally getpwuid()
in *nix builds and access to this function adds additional library
dependency which may block static builds in some cases.
TODO: eliminate hb_UserName() from things like initial random seed
to not create unnecessary dependency.
* contrib/gtqtc/gtqtc1.cpp
+ enable software input panel (virtual keyboard) in iOS builds
* src/common/hbprintf.c
* removed modfl() protection with old HB_OS_IPHONE macro.
If someone will need it for some old iOS versions then please read
it protected by HB_OS_IOS and __IPHONE_OS_VERSION_MIN_REQUIRED
macros or inform me about the exact iOS version which do not support
modfl() and I'll add it.
* include/hbatomic.h
* disable GCC atomic macros for GCC <= 4.5 in OS2 builds.
They can be manually enabled by users using:
set HB_USER_CFLAGS=-DHB_USE_GCCATOMIC
* include/hbsetup.h
* set HB_OS_IOS when __IPHONE_OS_VERSION_MIN_REQUIRED is defined
* include/hbsetup.h
* src/common/hbver.c
* detect 64bit ARM CPUs
* contrib/hbct/envparam.c
* contrib/hbnf/getenvrn.c
! disabled ENVPARAM() and FT_GETE() in iOS builds
+ added support for FT_GETE() in OS2 builds
* contrib/hbct/ctwin.c
! added protection against GPF in hb_ctwGetPosWindow() called before
any window is open. It's correct version of this fix.
* contrib/hbmemio/memio.c
* contrib/xhb/xhbfunc.c
! fixed size of filename buffer - it should be exactly HB_PATH_MAX
* src/rtl/itemseri.c
! fixed stupid typo which could cause buffer overrun during
serialization of hash items with default value.
Tanks to Abe for reporting the problem.
* src/rdd/workarea.c
! fixed typo in RDDI_AUTOORDER type - it should be numeric
just like in _SET_AUTORDER. Many thanks to Rolf for locating
the problem
* contrib/hbnetio/netiosrv.c
* contrib/hbtcpio/tcpio.c
* call hb_socketShutdown() before hb_socketClose() to force output
buffer flush in systems like MS-Windows.
* src/debug/dbgentry.c
! fixed typo in my previous commit for AltD() function detection
Thanks to Franček Prijatelj for reporting the problem and Abe
for self contain example
* src/rdd/dbfcdx/dbfcdx1.c
* reverted byte order in Harbour CDX signature - by mistake I used
little endian. When existsing index is open then reverted signatures
are accepted for backward compatiblity though they will be removed
in the future.
* src/rdd/workarea.c
* move results of EVALBLOCK() RDD method from Harbour stack return item
to workarea valResult item instead of copping it.
; Warning: This modification may exploit problems in code which
wrongly looks for result of EVALBLOCK() RDD method in
HVM stack return item instead of workarea valResult item.
* include/harbour.hbx
* src/vm/cmdarg.c
+ added new PRG function
hb_ACmdLine() -> <array>
borrowed from Viktor's branch (2015-03-12 03:02 UTC+0100 Viktor Szakats)
It returns array with all command line parameters. Unlike
hb_AParams( __dbgProcLevel() - 1 )
hb_ACmdLine() returns all parameters also hidden ones just like
hb_CmdLine() function and hb_argv()/hb_argc()
Please also remember that hb_AParams() returns current value of
parameters which could be changed bu user code so they can be different
then original parameters passed to given function.
* src/rtl/gtchrmap.c
* casting
* include/std.ch
* synced casing with Viktor's branch
* include/std.ch
+ added VIA and CODEPAGE parameters to SORT TO and TOTAL TO commands
* formatting
* include/hbsix.ch
* synced SIX3 compatible SORT TO command with core SORT TO parameters
* include/hbapirdd.h
* include/hbusrrdd.ch
+ added DBTF_RECALL flag which disables transferring record DELETED flag
* src/rdd/dbcmd.c
* src/rdd/workarea.c
! disable transferring DELETED flag to destination area in SORT TO /
__dbArrange() operations
* src/rdd/delim1.c
* src/rdd/sdf1.c
+ added dummy RECALL() methods - now RECALL() can be executed by workarea
TRANSREC() method when DBTF_RECALL flag is set
* src/rdd/dbf1.c
! restored the line with initialization of allocated memory buffer
I deleted by mistake removing my private comments before commit.
Without this line sort could randomly crash on small tables (less
then 65537 sorted records)
* include/Makefile
- include/hbdbsort.h
* src/rdd/Makefile
- src/rdd/hbdbsort.c
* src/rdd/dbf1.c
- completely removed old code used in DBF* RDDs as low level backend
for SORT TO ... command and __dbArrange() function.
It was buggy and extremely inefficient in some cases, i.e. after
20 hours I killed process which was sorting table with 2'000'000
records in reverted order so I cannot even say how much time it
needed.
* src/rdd/dbf1.c
+ added new code for table sorting in DBF* RDDs
(SORT TO ... / __dbArrange() backend)
New code fixes many different problems which existed in previous one
like missing support for national collation, wrong descending orders,
wrong sorting of numeric fields with negative values, missing support
for sorting many field types, missing support for transferring MEMO
fields, missing support for transferring records to table with different
field structure or serving by different RDD, etc.
New code is also many times faster then the old one. In practice it
means is now usable for tables with more then few thousands records,
i.e. the test table with 2'000'000 records I used with old code was
copied in sorted order in 13 secs. when pure COPY TO needed 10 secs.
Now it's possible to export sorted tables to different RDDs, i.e.
using DELIM or SDF RDDs in desitnation area.
New code is written in general form without any local to DBF* RDDs
extensions so it can be adopted as base in any other RDD. Probably
I'll move it to default workarea methods so it will be inherited by
all Harbour RDDs and only if necessary authors of some RDDs may
overload it, i.e. to move the operation to the server side in remote
RDDs when source and destination tables are processed by the same
server.
This modification closes the last known for years bug or rather bag
of bugs ;-) in Harbour.
; NOTE: For large tables new sorting algorithm may access source records
more then once. It means that results may be wrongly sorted when
sorted fields in exported records are modified concurrently by
other station during exporting. This can be easy eliminated by
copping source records to temporary file anyhow it will introduce
additional overhead in all cases and user can easy eliminate the
problem by simple FLOCK before sort or making export to temporary
file and then sorting this file or he can simply ignore this
problem as unimportant in the specific situation so I decided to
not implement double copping.
I haven't tested what Cl*pper exactly does in such case so
I cannot say if current behavior is or isn't Cl*pper compatible.
* src/rdd/dbcmd.c
! fixed __dbArrange() to allow record transfer with the same conditions
as __dbTrans() just like Cl*pper does.
Low level RDD code should respect it, i.e. it should be possible to
sort using fields which exist only in source workarea, the order
and number of fields in source and destination workareas can be
completely different, etc.
Low level DBF* SORT() method is completely broken in such cases and
has to be rewritten.
* contrib/hbtip/smtpcli.prg
! do not execute STARTTLS command if server does not report it's supported
(issue #90)
* src/rdd/dbcmd.c
* use DBI_TRANSREC in __dbTrans() and __dbArrange() (pure record copping
without sorting)
* contrib/hbwin/win_bmp.c
! fixed copy and past typo in my last modification - thanks to
Juan Francolino for reporting the problem and to Alexander
Czjczyński for locating the reason. It closes issue #91.
* contrib/hbtip/smtpcli.prg
* be sure that server answer after HELO command (:open() method) is
fully consumed
* contrib/hbtip/sendmail.prg
! removed redundant waiting for sever answer after opening connection
without authentication - it fixes timeout delay in such case
! do not create TIPClientSMTP() object twice when it's not necessary
% small code simplification
* contrib/hbtip/sendmail.prg
! fixed wrong login conditions - AICS it's old problem which had existed
from very long time.
* contrib/hbtip/smtpcli.prg
! eliminated redundant processing EHLO processing
* contrib/hbtip/smtpcli.prg
! added missing space after AUTH PLAIN
! resend EHLO command after STARTTLS
; Thanks to Rolf for information about both problems.
* contrib/hbtip/client.prg
* removed trailing spaces
* contrib/hbtip/hbtip.hbp
* contrib/hbtip/encurlc.c
+ contrib/hbtip/mime.c
+ contrib/hbtip/misc.c
- contrib/hbtip/utils.c
* synced with Viktor's branch
* renamed some variables to follow rules used by Harbour
% use binary search to locate mime extension
* some minor cleanups and fixes
* contrib/hbtip/smtpcli.prg
* synced with Viktor's branch - it should fix the problem with
unconditional bind with HBSSL library after last Jean's patch.
* include/hbapi.h
* src/vm/garbage.c
+ added hb_gcDummyClear() function
* include/hbapirdd.h
* include/hbusrrdd.ch
+ added DBTF_CPYCTR constant value - when set in dbTransInfo.uiFlags
then after record transfer field counters should to be copied from
source to destination area
* include/hbapirdd.h
* src/rdd/wafunc.c
+ added new C functions hb_dbTransInfoPut() and hb_dbTransInfoGet()
which allow to store and retrieve pointer to DBTRANSINFO structure
into/from HB_ITEM with strict type verification.
* src/rdd/wafunc.c
* pass pointer to DBTRANSINFO structure as argument of DBI_TRANSREC
action. It allows RDD serving destination area to decide which
fields and how should be transferred updating uiFlags, uiItemCount
and lpTransItems members of DBTRANSINFO.
If RDD removes all fields from DBTRANSINFO structure (uiItemCount==0)
or does not return HB_SUCCESS for DBI_TRANSREC action (default WA
implementation returns HB_SUCCESS so it's not necessary to overload
it if RDD does not make any additional operations) then record
transfer is interrupted.
* copy field counters only when destination area asked about it setting
DBTF_CPYCTR in dbTransInfo.uiFlags in DBI_TRANSREC action.
* src/rdd/dbf1.c
* do not copy automatically updated fields when destination area
is not empty
* set DBTF_CPYCTR to indicate that counters should be copied from
source to destination area when original value of automatically
updated fields are transferred
; Now DBF* RDDs in Harbour respects the following rules for record
transfer operations (COPY TO / APPEND FROM) with automatically
updated fields:
- COPY TO transfers original values to destination table and
finally copy counters from the source table to destination one
so autoincrement fields in both tables after next append will be
initialized with the same values regardless of number of copied
records - even if only single record is copied then counters in
destination table will inherit next values for new record from
the source table. Also values of RowVer and ModTime fields are
copied from source to destination table and not updated during
transfer operation.
- APPEND FROM works like COPY TO (original field values and then
counters are copied to destination table) if the source table
supports counters and destination table is empty and FLocked()
or opened in exclusive mode.
If source table does not support counters for given fields, i.e.
it is processed by transfer RDD like DELIM or SDF (RDT_TRANSFER)
or destination table is not empty or opened in shared mode and
FLock is not set when APPEND FROM is executed then automatically
updated fields (counters, RowVer, ModTime) are not copied and
initialized with new values like for each new record added to
destination table.
* ChangeLog.txt
! typo in last ChangeLog entry
* include/hbapi.h
! fixed HB_ISMEMO() macro, original version was accepting the same
items as HB_ISCHAR() so it was not compatible with ISMEMO() macro
in Cl*pper.
* src/rtl/valtype.c
* use HB_ISMEMO() macro
* src/rdd/dbf1.c
* src/rtl/hbinet.c
* pacified warnings (Thanks to Grigory)
* src/rdd/dbcmd.c
* src/rdd/wafunc.c
* small code simplification and cleanup
! protection against GPF when wrong parameters are passed to __dbArrange()
+ added support for transferring records using __dbArrange() to area with
different fields order (low level driver may refuse to finish such
operation but not it's possible.
* contrib/rddads/ads1.c
! use AdsSetLongLong() (if available) instead of AdsSetDouble() to not
strip less significant bits from 64bit integer number during conversion
to double
* allow ADS to decide if writing into rowver and modtime fields is legal
instead of generating our own arbitrary RTE
* include/dbinfo.ch
* src/rdd/workarea.c
+ added new dbInfo() action DBI_TRANSREC
It indicates if area is destination table of currently processed COPY TO
or APPEND FROM operation.
* include/hbapirdd.h
* src/rdd/wafunc.c
+ added new C function:
HB_ERRCODE hb_dbTransCounters( LPDBTRANSINFO lpdbTransInfo );
It copies field counters from source into destination table used
in transfer operation.
* src/rdd/dbcmd.c
* src/rdd/wafunc.c
+ call DBI_TRANSREC to inform destination area that record transfer
operation starts and stop. It allows destination RDD to change
rules used for assign to automatically updated fields, i.e. unblock
such operation.
+ call hb_dbTransCounters() to update counters in destination table
after COPY TO operation
* src/rdd/sdf1.c
* src/rdd/delim1.c
* clear AutoInc flag
* src/rdd/dbf1.c
+ allow to set get and set counter for RowVer fields using DBS_COUNTER
action
* return HB_FAILURE for DBS_COUNTER and DBS_STEP if it's not supported
by given field.
+ added support for DBI_TRANSREC - in case of DBF* RDDs it unblocks
writing to automatically updated fields
* contrib/hbodbc/odbc.c
* contrib/hbodbc/sql.ch
* minor formatting to sync with Viktor's branch
+ added missing defines from Viktor's branch
* contrib/rddads/ads.ch
* contrib/rddads/adsfunc.c
+ added AdsStmtSetTableReadOnly( <nMode> ) -> <lSuccess>
(From Viktor's branch: 2015-01-21 18:43 UTC+0100 Viktor Szakats)
+ added ADS_REFRESHCOUNT constant and
AdsGetRecordCount( [<nHandleType:ADS_TABLE>], ;
[<nFilterOption:ADS_RESPECTFILTERS>], @nCount ) -> <nErrorCode>
(From Viktor's branch: 2014-01-19 13:42 UTC+0100 Viktor Szakats)
! fixed connection handle parameter position in AdsDDRemoveTable()
It was 4-th:
AdsDDRemoveTable( <cTableName>, <deleteFile>, , [ <nConnection> ] )
-> <lResult>
Now is 3-rd:
AdsDDRemoveTable( <cTableName>, <deleteFile>, [ <nConnection> ] )
-> <lResult>
(From Viktor's branch: 2014-01-14 23:53 UTC+0100 Viktor Szakats)
* contrib/rddads/rddads.h
+ autodetection support for 11.10
(From Viktor's branch: 2013-12-26 01:22 UTC+0100 Viktor Szakáts)
* contrib/rddads/adsx.c
* use hb_xgrabz()
* formatting
* contrib/rddsql/hbrddsql.h
* contrib/rddsql/sqlbase.c
* added const qualifier to SDD method pointer in SQLBASEAREA
* declare default SDD method table with const qualifier
* added s_ prefix to the name of static variable with SDD methods
% optimized GOHOT() method
* use hb_xgrab() instead of hb_xalloc() to force error when out of memory
* use hb_xgrabz()
* contrib/rddsql/sqlmix.c
* use hb_xgrabz()
* contrib/sddfb/core.c
* added s_ prefix to the name of static variable with SDD methods
% removed unnecessary memset()
% optimized GOTO() method
! fixed very bad typo in record set resizing - for each record 64 dummy
items were added to array with records so finally this array was 64
times longer then necessary.
* contrib/sddmy/core.c
* added s_ prefix to the name of static variable with SDD methods
+ added new field types from from Viktor's branch
* use hb_xgrabz()
% removed redundant comparison to NULL
* contrib/sddoci/core.c
* added s_ prefix to the name of static variable with SDD methods
* check OCI_Initialize() result and generate error if fails
(synced with Viktor's branch)
* minor formatting to sync with Viktor's branch
% removed unnecessary memset()
% optimized GOTO() method
! fixed very bad typo in record set resizing - for each record 64 dummy
items were added to array with records so finally this array was 64
times longer then necessary.
* contrib/sddodbc/core.c
* replaced unnecessary hb_xgrabz() with hb_xgrab()
! fixed very bad typo in record set resizing - for each record 64 dummy
items were added to array with records so finally this array was 64
times longer then necessary.
* contrib/sddpg/core.c
* added s_ prefix to the name of static variable with SDD methods
* use hb_xgrabz()
* contrib/sddsqlt3/core.c
* added s_ prefix to the name of static variable with SDD methods
* minor formatting to sync with Viktor's branch
! fixed memory leak when RTE ESQLDD_STMTALLOC is generated
(fix from Viktor's branch)
% removed unnecessary memset()
! fixed very bad typo in record set resizing - for each record 64 dummy
items were added to array with records so finally this array was 64
times longer then necessary.
* contrib/sddfb/core.c
* contrib/sddmy/core.c
* contrib/sddoci/core.c
* contrib/sddodbc/core.c
* contrib/sddpg/core.c
* contrib/sddsqlt3/core.c
! clear dbFieldInfo structure before use - it resolves problems with
random field flags caused by uninitialized uiFlags member
* minor cleanup in variable names
* use hb_xgrabz()
* contrib/sddodbc/core.c
+ added support for NULLABLE, UNICODE and BINARY field flags
+ added support for SQL_BINARY fields
! fixed SQL_TIME mapping to Harbour field types.
It was mapped as HB_FT_DATE instead of HB_FT_TIME.
! fixed extracting integer values on on platforms where long int is
64 bit integer (in practice all 64bit *nixes). SQL_C_LONG should be
used with SQLINTEGER not 'long int'.
* contrib/hbodbc/odbc.c
+ add support for different data types in SQLGetData()
The original version was returning different types in their binary
representation. Current implementation is based on similar one from
Viktor's branch (2014-07-06 16:40 UTC+0200 Viktor Szakats) with
small but important fixes.
! modified hb_odbcNumSetLen() to not break 64bit integers by casting
to double value
* contrib/hbodbc/sql.ch
+ added SQL_WCHAR
* contrib/hbodbc/todbc.prg
+ use extended SQLGetData() and hb_odbcNumSetLen() functionality to
extract ODBC data
% few small optimization and casing usually based on Viktor's branch
BTW pre incrementations/decrementations used in PUSH context are
faster then post ones.
* contrib/hbodbc/odbc.c
* rewritten function SQLGetData() - new code is much simpler and
fixes few bugs
* contrib/hbodbc/todbc.prg
% eliminated unnecessary AAdd() when final array size is already known
! do not round numbers read number to default number of decimal places