Opened 16 years ago
Closed 16 years ago
#2953 closed bug (fixed)
Wrong printf-flag in log message
Reported by: | Adek336 | Owned by: | axeld |
---|---|---|---|
Priority: | normal | Milestone: | R1 |
Component: | System/Kernel | Version: | R1/pre-alpha1 |
Keywords: | Cc: | ||
Blocked By: | Blocking: | ||
Platform: | All |
Description
src/system/kernel/int.c
219 } else { 220 // this is a shared interrupt vector, we cannot just disable it - 221 dprintf("More than 99%% interrupts of vector %d are unhandled\n", + 221 dprintf("More than 99\% interrupts of vector %d are unhandled\n", 222 vector); 223 }
I think this solves the erroneous log messages that go like
More than 99-1nterrupts of...
instead of
More than 99% interrupts of...
Change History (6)
comment:1 by , 16 years ago
comment:2 by , 16 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Indeed, "%%" is perfectly legal, just our vsnprintf() did not handle it correctly.
Fixed in hrev28323.
comment:3 by , 16 years ago
Resolution: | fixed |
---|---|
Status: | closed → reopened |
Doesn't yet work:
dprintf("ziom%%ziom\n"); dprintf("%% in\n"); dprintf("yo %% ziom\n");
yields
ziom%ziom 1701523315n yo %ziom
where the last two are wrong.
comment:5 by , 16 years ago
Component: | - General → System/Kernel |
---|
comment:6 by , 16 years ago
Resolution: | → fixed |
---|---|
Status: | reopened → closed |
You obviously tested with a wrong release, this all works flawlessly here.
Note:
See TracTickets
for help on using tickets.
Mm, no, \% results in the compiler warning about incorrect number of arguments for format.
also %% works correctly with printf from userland code, so something else seems to be wrong here.