diff options
Diffstat (limited to 'src/initlog.c')
-rw-r--r-- | src/initlog.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/initlog.c b/src/initlog.c index 39579eeb..ee7dbd42 100644 --- a/src/initlog.c +++ b/src/initlog.c @@ -272,8 +272,9 @@ int logEvent(char *cmd, int eventtype,char *string) { if (cmd) { logentry.cmd = strdup(basename(cmd)); - if ((logentry.cmd[0] =='K' || logentry.cmd[0] == 'S') && ( 30 <= logentry.cmd[1] <= 39 ) - && ( 30 <= logentry.cmd[2] <= 39 ) ) + if ((logentry.cmd[0] =='K' || logentry.cmd[0] == 'S') && + ( logentry.cmd[1] >= '0' && logentry.cmd[1] <= '9' ) && + ( logentry.cmd[2] >= '0' && logentry.cmd[2] <= '9' ) ) logentry.cmd+=3; } else logentry.cmd = strdup(_("(none)")); @@ -298,8 +299,9 @@ int logString(char *cmd, char *string) { if (cmd) { logentry.cmd = strdup(basename(cmd)); - if ((logentry.cmd[0] =='K' || logentry.cmd[0] == 'S') && ( 30 <= logentry.cmd[1] <= 39 ) - && ( 30 <= logentry.cmd[2] <= 39 ) ) + if ((logentry.cmd[0] =='K' || logentry.cmd[0] == 'S') && + ( logentry.cmd[1] >= '0' && logentry.cmd[1] <= 0x39 ) && + ( logentry.cmd[2] >= '0' && logentry.cmd[2] <= 0x39 ) ) logentry.cmd+=3; } else logentry.cmd = strdup(_("")); |