From 19b2fdeaff9d8ed5f0fd49a31708215baf76567e Mon Sep 17 00:00:00 2001 From: Przemyslaw Czerpak Date: Tue, 31 Jul 2007 10:50:56 +0000 Subject: [PATCH] 2007-07-31 12:50 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl) * harbour/contrib/tip/utils.c * harbour/contrib/tip/encmthd.c * changed hb_retclenAdoptRaw() to hb_retclen_buffer() --- harbour/ChangeLog | 5 +++++ harbour/contrib/tip/encmthd.c | 4 +--- harbour/contrib/tip/utils.c | 4 ++-- 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/harbour/ChangeLog b/harbour/ChangeLog index 113a0d2d5d..12c9893111 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -8,6 +8,11 @@ 2002-12-01 13:30 UTC+0100 Foo Bar */ +2007-07-31 12:50 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl) + * harbour/contrib/tip/utils.c + * harbour/contrib/tip/encmthd.c + * changed hb_retclenAdoptRaw() to hb_retclen_buffer() + 2007-07-30 18:10 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl) + harbour/tests/foreach2.prg * added example for FOR EACH overloading diff --git a/harbour/contrib/tip/encmthd.c b/harbour/contrib/tip/encmthd.c index 2190b2e4bb..b2823863c7 100644 --- a/harbour/contrib/tip/encmthd.c +++ b/harbour/contrib/tip/encmthd.c @@ -497,9 +497,7 @@ HB_FUNC( TIPENCODERURL_ENCODE ) nPos++; } - cRet[ nPosRet ] = 0; - /* this function also adds a zero */ - hb_retclenAdoptRaw( cRet, nPosRet ); + hb_retclen_buffer( cRet, nPosRet ); } HB_FUNC( TIPENCODERURL_DECODE ) diff --git a/harbour/contrib/tip/utils.c b/harbour/contrib/tip/utils.c index 3641754089..ac6c0e3196 100644 --- a/harbour/contrib/tip/utils.c +++ b/harbour/contrib/tip/utils.c @@ -139,7 +139,7 @@ HB_FUNC( TIP_TIMESTAMP ) { szRet = (char *) hb_xrealloc( szRet, nLen + 1 ); } - hb_retclenAdoptRaw( szRet, nLen ); + hb_retclen_buffer( szRet, nLen ); } @@ -199,7 +199,7 @@ HB_FUNC( TIP_TIMESTAMP ) { szRet = (char *) hb_xrealloc( szRet, nLen + 1 ); } - hb_retclenAdoptRaw( szRet, nLen ); + hb_retclen_buffer( szRet, nLen ); } #endif