From 7750da9e9f483a97f495373bc79cfc20514a47b2 Mon Sep 17 00:00:00 2001 From: Viktor Szakats Date: Wed, 10 Oct 2012 17:17:21 +0000 Subject: [PATCH] 2012-10-10 19:10 UTC+0200 Viktor Szakats (harbour syenar.net) * bin/commit.hb ! fixed finding last changelog entry in ChangeLogs which have non-ASCII, non-UTF8 chars (f.e. any 8-bit high chars, f.e. legacy accented or drawing chars, like it is the case with hwgui's ChangeLog file, where one such char caused the problem.) --- harbour/ChangeLog | 8 ++++++++ harbour/bin/commit.hb | 3 +++ 2 files changed, 11 insertions(+) diff --git a/harbour/ChangeLog b/harbour/ChangeLog index e92a0dfc1e..f9913ed436 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -16,6 +16,14 @@ The license applies to all entries newer than 2009-04-28. */ +2012-10-10 19:10 UTC+0200 Viktor Szakats (harbour syenar.net) + * bin/commit.hb + ! fixed finding last changelog entry in ChangeLogs which + have non-ASCII, non-UTF8 chars (f.e. any 8-bit high + chars, f.e. legacy accented or drawing chars, like + it is the case with hwgui's ChangeLog file, where one + such char caused the problem.) + 2012-10-10 15:49 UTC+0200 Viktor Szakats (harbour syenar.net) * bin/commit.hb ! fixed GMT sign in inserted header when offset is negative diff --git a/harbour/bin/commit.hb b/harbour/bin/commit.hb index 55c17e018e..e3f5f2cb38 100644 --- a/harbour/bin/commit.hb +++ b/harbour/bin/commit.hb @@ -45,6 +45,7 @@ PROCEDURE Main() LOCAL cHit LOCAL nPos LOCAL cMyName + LOCAL cOldLang IF Empty( aChanges ) OutStd( hb_progname() + ": no changes" + hb_eol() ) @@ -75,10 +76,12 @@ PROCEDURE Main() // ; cLog := MemoRead( "ChangeLog" ) + cOldLang := hb_cdpSelect( "EN" ) cHit := hb_AtX( "\n[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9] [0-9][0-9]:[0-9][0-9] UTC[\-+][0-9][0-9][0-9][0-9] ", cLog ) IF Empty( cHit ) cHit := "" ENDIF + hb_cdpSelect( cOldLang ) nPos := At( AllTrim( cHit ), cLog ) IF nPos > 0