mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-22 22:16:16 +02:00
nix-log2xml: Handle UTF-8 characters
C++ chars can be negative...
This commit is contained in:
parent
9367046fef
commit
e9b609bf9a
1 changed files with 1 additions and 1 deletions
|
@ -137,7 +137,7 @@ void Decoder::finishLine()
|
||||||
if (line[i] == '<') cout << "<";
|
if (line[i] == '<') cout << "<";
|
||||||
else if (line[i] == '&') cout << "&";
|
else if (line[i] == '&') cout << "&";
|
||||||
else if (line[i] == '\r') ; /* ignore carriage return */
|
else if (line[i] == '\r') ; /* ignore carriage return */
|
||||||
else if (line[i] < 32 && line[i] != 9) cout << "�";
|
else if (line[i] >= 0 && line[i] < 32 && line[i] != 9) cout << "�";
|
||||||
else if (i + sz + 33 < line.size() &&
|
else if (i + sz + 33 < line.size() &&
|
||||||
string(line, i, sz) == storeDir &&
|
string(line, i, sz) == storeDir &&
|
||||||
line[i + sz + 32] == '-')
|
line[i + sz + 32] == '-')
|
||||||
|
|
Loading…
Reference in a new issue