From 78b2bd7d0d408a7f8d679a4e97a0260900211fb6 Mon Sep 17 00:00:00 2001 From: k-m_schindler Date: Thu, 22 Apr 2010 17:50:50 +0000 Subject: use Log.LogError instead of writeln git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/trunk@2278 b956fd51-792f-4845-bead-9b4dfca2ff2c --- src/encoding/Auto.inc | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) (limited to 'src') diff --git a/src/encoding/Auto.inc b/src/encoding/Auto.inc index 2f7faa0c..487e2e42 100644 --- a/src/encoding/Auto.inc +++ b/src/encoding/Auto.inc @@ -82,9 +82,7 @@ begin if self.Regex = Nil then begin - {$IFDEF CONSOLE} - writeln('ERROR: UTF8 Regex compilation failed: ', AnsiString(Error), ' at ', ErrorOffset); - {$ENDIF} + Log.LogError ('UTF8 Regex compilation failed: ' + AnsiString(Error) + ' at ' + IntToStr(ErrorOffset), 'EncoderAuto.Create'); end else begin @@ -93,17 +91,13 @@ begin if Error <> Nil then begin - {$IFDEF CONSOLE} - writeln('ERROR: UTF8 Regex study failed: ', AnsiString(Error)); - {$ENDIF} + Log.LogError ('UTF8 regex study failed: ' + AnsiString(Error), 'EncoderAuto.Create'); end; end; end else begin - {$IFDEF CONSOLE} - writeln('ERROR: pcre not loaded. utf-8 autodetection will not work.'); - {$ENDIF} + Log.LogError ('pcre not loaded. utf-8 autodetection will not work.', 'EncoderAuto.Create'); end; end; -- cgit v1.2.3