Subject: bug#17800: seq weirdness with -0

From: Rasmus Villemoes <[email-masked]>
Date: Wed, 18 Jun 2014 11:41:43 +0200

$ ./seq --version | head -1
seq (GNU coreutils) 8.22.119-8a51b

./seq -0 n works fine when n is a single digit:

$ ./seq --separator=, -0 5
-0,1,2,3,4,5

But something weird happens when one uses a number >= 10:

$ ./seq --separator=, -0 10
-0,-1,-2,-3,-4,-5,-6,-7,-8,-9,.0,.1,.2,.3,.4,.5,.6,.7,.8,.9,/0,/1,/2,/3,/4,/5,/6,/7,/8,/9,00,01,02,03,04,05,06,07,08,09,10

[It also happens without the --separator; I just use that to save
vertical space.] This smells of ASCII, and looking at the code, the
problem is very likely to be the seq_fast/incr functions. I don't know
what the simplest fix is, though.

Rasmus