bug-coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#17961: "od -c" producing numbers greater than 255 ?


From: Sebastian Pipping
Subject: bug#17961: "od -c" producing numbers greater than 255 ?
Date: Sun, 06 Jul 2014 20:54:40 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.6.0

Hello!


I have observed od printing byte values greater than 255 (e.g 302 and
303) and wonder if that's a bug and if not what's the idea behind it.

I'm running coreutils version 8.22.

My command to re-produce is

  python3 -c 'for i in range(256): print("%c" % i, end="")' | od -c

Please note that Python is producing UTF-8 here.

This is the output I get:


# python3 -c 'for i in range(256): print("%c" % i, end="")' | od -c
0000000  \0 001 002 003 004 005 006  \a  \b  \t  \n  \v  \f  \r 016 017
0000020 020 021 022 023 024 025 026 027 030 031 032 033 034 035 036 037
0000040       !   "   #   $   %   &   '   (   )   *   +   ,   -   .   /
0000060   0   1   2   3   4   5   6   7   8   9   :   ;   <   =   >   ?
0000100   @   A   B   C   D   E   F   G   H   I   J   K   L   M   N   O
0000120   P   Q   R   S   T   U   V   W   X   Y   Z   [   \   ]   ^   _
0000140   `   a   b   c   d   e   f   g   h   i   j   k   l   m   n   o
0000160   p   q   r   s   t   u   v   w   x   y   z   {   |   }   ~ 177
0000200 302 200 302 201 302 202 302 203 302 204 302 205 302 206 302 207
0000220 302 210 302 211 302 212 302 213 302 214 302 215 302 216 302 217
0000240 302 220 302 221 302 222 302 223 302 224 302 225 302 226 302 227
0000260 302 230 302 231 302 232 302 233 302 234 302 235 302 236 302 237
0000300 302 240 302 241 302 242 302 243 302 244 302 245 302 246 302 247
0000320 302 250 302 251 302 252 302 253 302 254 302 255 302 256 302 257
0000340 302 260 302 261 302 262 302 263 302 264 302 265 302 266 302 267
0000360 302 270 302 271 302 272 302 273 302 274 302 275 302 276 302 277
0000400 303 200 303 201 303 202 303 203 303 204 303 205 303 206 303 207
0000420 303 210 303 211 303 212 303 213 303 214 303 215 303 216 303 217
0000440 303 220 303 221 303 222 303 223 303 224 303 225 303 226 303 227
0000460 303 230 303 231 303 232 303 233 303 234 303 235 303 236 303 237
0000500 303 240 303 241 303 242 303 243 303 244 303 245 303 246 303 247
0000520 303 250 303 251 303 252 303 253 303 254 303 255 303 256 303 257
0000540 303 260 303 261 303 262 303 263 303 264 303 265 303 266 303 267
0000560 303 270 303 271 303 272 303 273 303 274 303 275 303 276 303 277
0000600


I'm looking forward to your reply.  Please keep me in CC for now.

Best,



Sebastian





reply via email to

[Prev in Thread] Current Thread [Next in Thread]