aboutsummaryrefslogtreecommitdiffstats
path: root/src/encoding
diff options
context:
space:
mode:
Diffstat (limited to 'src/encoding')
-rw-r--r--src/encoding/Auto.inc12
1 files changed, 3 insertions, 9 deletions
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;