Re: trstring() has \ooo octal printing code, it's buggy
Herbert Xu <[email protected]> Mon, 16 Mar 2026 13:27:24 +0900
| Newsgroups | org.kernel.vger.dash |
|---|---|
| Message-ID | <[email protected]> |
Denys Vlasenko <[email protected]> wrote: > Good day, > putc('\\', tracefile); > putc(*p >> 6 & 03, tracefile); > putc(*p >> 3 & 07, tracefile); > putc(*p & 07, tracefile); > > The last three putc need '0' added to the char value: > they need to print '0...'7' bytes, not 0...7 Please send a patch. Thanks, -- Email: Herbert Xu <[email protected]> Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt