* 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
* ChangeLog.txt
* src/compiler/hbmain.c
* src/nortl/nortl.c
! save and restore SETs which can be modified by -fn[:[l|u]|-],
-fd[:[l|u]|-], -fp[:<char>] and -fs[-] compiler flags.
It fixes problem with HBMK2 so now above switches can be used
with HBMK2.
* src/rdd/delim1.c
* src/rdd/sdf1.c
! disabled code which allows to delete just added record.
It was not Cl*pper compatible and caused bad side effects
in COPY TO ... DELIM | SDF - deleted records were nor
copied
* contrib/hbodbc/odbc.c
* contrib/sddodbc/core.c
* updated to compile with UnixODBC 2.2.0
I slightly changed one #if condition used to define SQLTCHAR.
If it interacts with some other old UnixODBC version then
please let me know.
* contrib/hbssl/hbssl.h
* added HB_SSL_CONST macro which can be used instead of 'const'
qualifier to pacify "discards qualifier 'const'" warnings in
OpenSSL versions prior 0.9.8
* contrib/hbssl/evp.c
* contrib/hbssl/evpciph.c
* contrib/hbssl/evpenc.c
* contrib/hbssl/evpmd.c
* contrib/hbssl/ssl.c
* contrib/hbssl/sslctx.c
* use HB_SSL_CONST macro to pacify warnings in 0.9.6 and 0.9.7
OpenSSL versions
; Now HBSSL compiles cleanly without any warnings with different
OpenSSL final versions starting with 0.9.6
* contrib/gtwvg/gtwvgd.c
* contrib/gtwvg/gtwgud.c
! Fixed: a bug which was causing HB_GTI_SETPOS_XY/ROWCOL returning
wrong values in case it is called as GET method.
* contrib/hbssl/evpciph.c
* contrib/hbssl/hbssl.h
! added missing protection for EVP_rc5_32_12_16_cfb64()
* cleaned version macro usage to not force final versions until beta
ones is not confirmed to be broken
* contrib/hbssl/bio.c
* contrib/hbssl/err.c
* contrib/hbssl/evpciph.c
* contrib/hbssl/evpmd.c
* contrib/hbssl/hbssl.h
* contrib/hbssl/ssl.c
* contrib/hbssl/ssl_inet.c
! fixed compilation with older OpenSSL versions.
Now minimum supported version of OpenSSL is 0.9.6.
I tested current code only with finals releases (such releases
have 'f' as last hex digit in OPENSSL_VERSION_NUMBER) so it's
possible that some beta release may need additional tunes but now
adopting the code should be quite easy job for anyone who need
to use such OpenSSL version and has same very basic C knowledge.
When older OpenSSL versions are used then warnings:
"passing arg X discards qualifier 'const' from pointer target type"
can appear. I didn't pacified them to not hide some possible bugs
in the future though it breaks C++ compilation so maybe I'll add
such casting using macro redefined only for older versions.
; [TODO] check if HB_OPENSSL_OLD_OSX_ macro is still required and
if not then remove it. Maybe also other DARWIN macros can
be removed.
* package/harb_win.mft
* package/harb_win.rc
* bumped copyright year to 2015
* package/mpkg_win_nightly.bat
* package/winuni/mpkg_win_uni.bat
* enclosed paths in "" for names with spaces
* src/rdd/dbf1.c
+ added support for autoincrement fields with counter longer then 4 bytes
Warning: if someone created tables with such fields i.e. { "I:+", 8, 0 }
after my modification which added support for AutoInc flags in
all numeric DBF fields then he should update counters manually
using DBS_COUNTER flag. New code uses 64bit counters for such
field located in different part of DBFFIELD structure.
* src/compiler/cmdcheck.c
! fixed error messages when wrong parameters are passed.
When wrong parameters are taken from HARBOURCMD or CLIPPERCMD
"Bad command line option '%s'"
error is generated and
"Bad command line parameter '%s'"
when wrong parameters are from command line.
New behavior is Cl*pper compatible.
* contrib/hbssl/tests/inetssl.prg
* contrib/rddads/ads1.c
* src/rtl/teditor.prg
* formatting of my recent modifications taken from Viktor's branch
* src/common/hbfsapi.c
* src/compiler/complex.c
* formatting
* include/hbset.h
* src/vm/set.c
* src/nortl/nortl.c
+ add new C functions to change HVM set values:
hb_setSetFileCase(), hb_setSetDirCase(), hb_setSetDirSeparator(),
hb_setSetTrimFileName()
* include/hbcomp.h
* include/hbcompdf.h
* src/compiler/cmdcheck.c
* src/compiler/hbmain.c
* src/compiler/ppcomp.c
* src/compiler/genc.c
* src/compiler/hbusage.c
* src/nortl/nortl.c
* rewritten code used to parse command line and environment parameters.
New code is covered by GPL + Harbour exception license.
All parameters are decoded by only one function and whole code is
smaller so it's much easier to modify this code.
! fixed some small bugs and incompatibilities with Cl*pper in parameter
parsing
! fixed -y undocumented (YYDEBUG) switch
- removed -x[<prefix>] set symbol init function name prefix (for .c only)
compiler command line switch
* moved -fn[:[l|u]|-] -fd[:[l|u]|-] -fp[:<char>] and -fs[-] switches
parsing to core compiler library. Now these switches are also works
with compiler library linked with HBMK2.
; TOFIX: HBMK2 ignores -fn/-fd switches and allocates temporary names
which are not compatible with names used later by harbour
compiler when above switches are activated. HBMK2 should
parse parameters and update SET FILECASE / SET DIRCASE before
it creates temporary files.
* src/rtl/mlcfunc.c
! fixed MPosToLC() results for position in last line which have to
be moved after analyzing rest of line due to word wrapping.
* src/rtl/teditor.prg
* rewritten whole internal code critical for basic functionality.
+ resolved the problem with keycode conflicts for GTs which
support extended keycodes.
+ added support missing MemoEdit() editor functionality.
; Number of bugs and mistakes was to big to try to update it.
New code is smaller and simpler. I tried to keep compatibility
with previous version and added to new version most of "helper"
methods which are not used in MemoEdit() at all anyhow I cannot
guaranty that all existing code using TEditor will work without
modifications, i.e. I had to remove :SetPos() and all logic bound
with it because it was to hard for my brain to understand this
idea and/or functionality.
If someone needs strict compatibility with previous version then
he should add to his source code copy of old code.
Current code should addressed most of MemoEdit() problems with
text formatting and editing reported in the past though probably
not all. I have no spare time for precise tests of Cl*pper's
MemoEdit().
* src/rtl/memoedit.prg
* overload :InsertState() method to show <insert> SCOREBOARD message
* changed "Abort Edit? (Y/N)" message position to be Clipper compatible
* removed redundant keycode comparison
* do not ::SetPos HBEditor method - this method has been removed
* src/rtl/mlcfunc.c
* modified unpadded MemoLine() mode to return last blank
character in the line
* src/rtl/teditor.prg
! fixed typo in MemoLine() parameters
+ added lSoftCR parameter to GetText() - when it's true returned
text contains SoftCRs
* src/rtl/memoedit.prg
! return text with SoftCRs - Cl*pper compatible
; Above modifications fix initial and result text formatting
in MemoEdit() (#33)
* src/codepage/l_fr.h
+ added 'Ç' and 'ç' characters to set of french letters
; this modification affected "FRISO" and "FRWIN" codepages.
Users using them and above characters in index field should
reindex their databases.
* include/hbcpage.hbx
* src/codepage/Makefile
* src/codepage/cpfr850.c
+ src/codepage/cpfr850c.c
* renamed "FR850" codepage to "FR850C". This is is Cl*pper ntxfre.obj
compatible codepage.
If someone uses DBF files with indexes simultaneously with Cl*pper
applications using collation order defined in ntxfre.obj the he has
to use "FR850C" codepage in Harbour.
Warning: Any users using French "FR850" codepage so far should change
the code to "FR850C".
+ added new French codepage "FR850" with all French characters and
accented equal collation rules.
; above modifications close issue #88
* src/rdd/dbf1.c
* moved AutoInc field initialization to separate function
% removed unnecessary AutoInc initialization from RowVer fields
* cleanup few static function names
* src/rdd/dbf1.c
+ finished support for AutoInc flag (+) for all numeric fields (N, F, I, B)
in DBF* RDDs. Now user can define field like:
{ "COUNTER", "I:+", 4, 0 }
and they will work like autoincrement fields but without any assign
restrictions.
* include/hbznet.h
* src/rtl/hbinet.c
+ added new C function hb_znetInetTimeout()
* minor cleanup (local variables localization)
* contrib/hbssl/hbssl.hbm
* contrib/hbssl/hbssl.hbx
+ contrib/hbssl/ssl_inet.c
+ added support for SSL/TLS encryption in hb_inet*() sockets.
To enable SSL/TLS encryption on such socket it's enough to
call hb_inetSSL_connect() or hb_inetSSL_accept() passing as
1-st parameter hb_inet socket item with already established
connection and in in the 2-nd parameter SSL item. The peer
should call second function. In general hb_inetSSL_connect()
should be called by client and hb_inetSSL_accept() by server.
To use hb_inetSSL_accept() it's necessary to also set
certificated (at least self ;-)) encryption keys. See the
example I committed to test directory.
The exact syntax of new functions is:
hb_inetSSL_connect( <pSocket>, <pSSL> [, <nTimeout> ] )
hb_inetSSL_accept( <pSocket>, <pSSL> [, <nTimeout> ] )
To use hb_inet*() functions to connect with SSL/TLS server
Harbour users only have to call hb_inetSSL_connect() after
setting connection, i.e.:
IF !Empty( sock := hb_inetConnect( cServer, nPort ) )
ssl_ctx := SSL_CTX_new()
IF hb_inetSSL_connect( sock, SSL_new( ssl_ctx ) ) == 1
// SSL connection established
// now user can use all hb_inet*() functions is
// the same way as for raw TCP connections and
// all parameters like timeouts are fully supported
// but transmission is encrypted.
[...]
ENDIF
ENDIF
It's not longer necessary to use SSL_set_fd() + SSL_connect()
and then SSL_read() / SSL_write() / hb_SSL_read_line() /
hb_SSL_read_all().
BTW hb_SSL_read_line() and hb_SSL_read_all() in HBSSL library
are broken and have to be fixed.
TODO: Now HBTIP library can be nicely simplified and additional
code for SSL/TLS read/write operations removed. It's
enough to once call hb_inetSSL_connect() if SSL/TLS
encryption is needed.
+ contrib/hbssl/tests/inetssl.prg
+ added test code for hb_inet*() SSL/TLS connections.
It's client and server example which also generates self
certificated encryption keys running openssl command.
If this code is linked with non console GT then user
should generated certificates himself (see comment in
LoadCertificates() function for more information).
* contrib/xhb/xhberr.prg
* contrib/xhb/xhb.hbx
- removed __BreakBlock() function. The Harbour core implementation
of __BreakBlock() function fully replaces it and is more efficient
because it does not create new codeblock on each call.
* src/rtl/hardcr.c
! fixed HardCR() to work with codepages using custom character encoding
in which SoftCR can be part of valid character, i.e. UTF8.
* ChangeLog.txt
* typos in prev my entry
* include/harbour.hbx
* src/vm/hvm.c
+ added new PRG function:
__BreakBlock() -> {|e| Break( e ) }
* include/hbexprb.c
% replace {|e| Break( e ) } with __BreakBlock() function call.
__BreakBlock() returns exactly the same codeblock on each call
so using it save memory and improve a little bit speed because
it's not necessary to allocate new GC memory block and register
it in GC block list. Additionally in MT mode it eliminates mutex
lock necessary to register new GC block.
* src/rdd/workarea.c
+ added support for field flags in dbCreate()/dbStruct().
Flags can be passed in string with field type after ":", i.e.
"C:U"
means Unicode character field.
The following flags are recognized:
"N" - column can store null values
"B" - binary column
"+" - column is autoincrementing
"Z" - column is compressed
"E" - column is encrypted
"U" - column stores Unicode strings
* src/rdd/dbf1.c
+ added support for field flags in core DBF* RDDs.
; In core DBF* RDDs "N", "B", "U" and "+" flags are supported.
When "N" flag is used then special hidden field with NULL bits
is created. Such implementation is compatible with DBF created
by VFP.
* contrib/rddads/ads1.c
+ added support for field flags in ADS* RDDs
! added missing RTE when wrong field types are passed to dbCreate()
; The old format with long field names corresponding to ADS types is
still supported but I had to rewrite this code so please make real
life test and verify me. In few cases I slightly change the code and
now it can be a little bit more restrictive, i.e. typos in "AtutoInc"
field type will be detected (previous code checked only for 1-st
letter "A").