diff options
author | wtchang%redhat.com <devnull@localhost> | 2005-03-15 00:55:22 +0000 |
---|---|---|
committer | wtchang%redhat.com <devnull@localhost> | 2005-03-15 00:55:22 +0000 |
commit | d6413003ca04ba9db83f240d9d7177828566fc9a (patch) | |
tree | e930586ca8b5c93e080296f93ca50d721e3e4eca | |
parent | 5d6a1fe5a6f69512e56da0a6e96a9efad9b7536f (diff) | |
download | nspr-hg-d6413003ca04ba9db83f240d9d7177828566fc9a.tar.gz |
Bugzilla Bugs 255633, 285934: '-' must be the first or last character in
a scanlist, otherwise some implementations may interpret it to mean a
range of characters. Thanks to Frank Wein <bugzilla@mcsmurf.de> for the
bug report and suggesting the fix.
Tag: NSPRPUB_PRE_4_2_CLIENT_BRANCH
-rw-r--r-- | pr/src/io/prlog.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/pr/src/io/prlog.c b/pr/src/io/prlog.c index fea940c6..ab348d4f 100644 --- a/pr/src/io/prlog.c +++ b/pr/src/io/prlog.c @@ -219,7 +219,7 @@ void _PR_InitLog(void) PRInt32 bufSize = DEFAULT_BUF_SIZE; while (pos < evlen) { PRIntn level = 1, count = 0, delta = 0; - count = sscanf(&ev[pos], "%63[ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_]%n:%d%n", + count = sscanf(&ev[pos], "%63[ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_-]%n:%d%n", module, &delta, &level, &delta); pos += delta; if (count == 0) break; @@ -328,7 +328,7 @@ static void _PR_SetLogModuleLevel( PRLogModuleInfo *lm ) while (pos < evlen) { PRIntn level = 1, count = 0, delta = 0; - count = sscanf(&ev[pos], "%63[ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_]%n:%d%n", + count = sscanf(&ev[pos], "%63[ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_-]%n:%d%n", module, &delta, &level, &delta); pos += delta; if (count == 0) break; |