diff --git a/harbour/ChangeLog b/harbour/ChangeLog index 981cf44721..9a83ddf198 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -8,6 +8,10 @@ 2008-12-31 13:59 UTC+0100 Foo Bar (foo.bar foobar.org) */ +2009-01-27 02:22 UTC+0100 Viktor Szakats (harbour.01 syenar hu) + * source/rtl/version.c + ! Fixed hb_version( HB_VERSION_BUILD_DATE ). + 2009-01-27 00:39 UTC+0100 Viktor Szakats (harbour.01 syenar hu) * contrib/examples/uhttpd/uhttpd.prg ! Fixed RTE when in socket.c mode. diff --git a/harbour/source/rtl/version.c b/harbour/source/rtl/version.c index 256428658f..ec546ebd0d 100644 --- a/harbour/source/rtl/version.c +++ b/harbour/source/rtl/version.c @@ -91,21 +91,22 @@ HB_FUNC( HB_VERSION ) char szDate[ 9 ]; int iMonth; - memcpy( szDate, pszBuildDate + 7, 4 ); szDate[ 4 ] = szDate[ 5 ] = '0'; - szDate[ 6 ] = pszBuildDate[ 4 ] == ' ' ? '0' : pszBuildDate[ 4 ]; - szDate[ 7 ] = pszBuildDate[ 5 ]; - szDate[ 8 ] = '\0'; for( iMonth = 11; iMonth >= 0; iMonth-- ) { if( memcmp( pszBuildDate, s_months[ iMonth ], 3 ) == 0 ) { - hb_snprintf( szDate + 4, 2, "%02d", iMonth + 1 ); + hb_snprintf( szDate + 4, 3, "%02d", iMonth + 1 ); break; } } + memcpy( szDate, pszBuildDate + 7, 4 ); + szDate[ 6 ] = pszBuildDate[ 4 ] == ' ' ? '0' : pszBuildDate[ 4 ]; + szDate[ 7 ] = pszBuildDate[ 5 ]; + szDate[ 8 ] = '\0'; + hb_retds( szDate ); } else