seq with reverse sequences is broken in coreutils-5.0.91-r2. output from "seq 5 1" coreutils-5.0-r3: 5 4 3 2 1 coreutils-5.0.91-r2: (nothing) Reproducible: Always Steps to Reproduce: Expected Results: should produce correct reverse sequences Portage 2.0.49-r18 (default-x86-1.4, gcc-3.3.2, glibc-2.3.3_pre20031212-r0, 2.4.22-pre10-ac1) ================================================================= System uname: 2.4.22-pre10-ac1 i686 AMD Athlon(tm) XP 2400+ Gentoo Base System version 1.4.3.12 ccache version 2.3 [enabled] ACCEPT_KEYWORDS="x86 ~x86" AUTOCLEAN="yes" CFLAGS="-march=athlon-xp -mcpu=athlon-xp -O3 -pipe" CHOST="i686-pc-linux-gnu" COMPILER="gcc3" CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /usr/kde/2/share/config /usr/kde/3/s hare/config /usr/share/config /usr/share/texmf/dvipdfm/config/ /usr/share/texmf/ dvips/config/ /usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/c onfig/ /usr/share/texmf/xdvi/ /var/bind /var/qmail/alias /var/qmail/control /var /vpopmail/domains /var/vpopmail/etc" CONFIG_PROTECT_MASK="/etc/gconf /etc/env.d" CXXFLAGS="-march=athlon-xp -mcpu=athlon-xp -O3 -pipe" DISTDIR="/usr/gentoo-distfiles" FEATURES="autoaddcvs buildpkg ccache cvs digest nostrip sandbox xmanifestsign" GENTOO_MIRRORS="http://gentoo.ccccom.com http://mirrors.tds.net/gentoo ftp://ftp.ussg.iu.edu/pub/linux/gentoo http://gentoo.noved.org/ http://csociety- ftp.ecn.purdue.edu/pub/gentoo/" MAKEOPTS="-j1" PKGDIR="/usr/gentoo-packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/gentoo-cvs/gentoo-x86" PORTDIR_OVERLAY="/usr/local/portage" SYNC="rsync://rsync.gentoo.org/gentoo-portage" USE="3dnow X aalib acl acpi alsa amd apache2 apm arts avi berkdb bots cdr clearpasswd crypt cups curl directfb dvd encode esd ethereal expat fbcon firebird flash foomaticdb freetds gd gdbm ggi gif ginac gmtfull gmthigh gmtsuppl gmttria gnome gpm gps gtk gtk2 gtkhtml imap imlib innodb ipalias ipv6 jack java jikes jpeg junit kde ldap libg++ libwww lirc mad maildir mcal md5sum mikmod mmx motif mozilla mpeg mpi mysql nas ncurses nls oav offensive oggvorbis ospfapi oss pam pcap pda pdflib perl pic plotutils png pnp ppds python qhull qt readline samba sasl scanner sdl slang slp snmp socks5 spell sse ssl svga tcltk tcpd tetex tiff truetype type1 ungif usagi usb v4l vscan wmf wxwindows x86 xml xml2 xmms xv zlib"
seems like you have to set the increment to -1 for backwards seq to work I'm looking into a patch to enable the old behaviour
robin, can you check this with coreutils-5.0.91-r3 as well, please?
never mind :/
this is the relevant item from the coreutils ChangeLog: 2003-09-04 Paul Eggert <eggert@twinsun.com> * src/seq.c (step): Default to 1. (print_numbers): Allow the output to be empty. (main): The default step is 1, even if LAST < FIRST; as per documentation. now this raises the question of the correct behavior. should it be the same as sh-utils and coreutils previous to the broken version? eg 'seq 5 1' works, or should it return no output?
Created attachment 26082 [details, diff] seq.c.patch
fixed in 5.2.0