Your message dated Tue, 04 Dec 2007 23:47:01 +0000
with message-id <[EMAIL PROTECTED]>
and subject line Bug#453345: fixed in debianutils 2.28.1
has caused the attached Bug report to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what I am
talking about this indicates a serious mail system misconfiguration
somewhere.  Please contact me immediately.)

Debian bug tracking system administrator
(administrator, Debian Bugs database)

--- Begin Message ---
Package: debianutils
Version: 2.25.1
Severity: minor


Two bits of extraneous code to remove:

lines 30-33:
  30 case $PATH in
  31  *::) : "not *DIR:" ;;
  32   *:) PATH="$PATH:" ;;
  33 esac

Unless this is for some weird nonstandard bourne implementation, the
argument "not *DIR:" to the colon (:) builtin on line 31 is ignored, and
the whole purpose of the entire case statement, that of ensuring a
trailing colon, is unnecessary, as the tokenizer works fine when the last
token has no delimiter (e.g. "for i in 1 2 3; do echo $i; done" writes
three lines, as does "IFS=:; for i in 1:2:3; do echo $i; done" ... you
do not need "1:2:3:" to properly parse the last token "3").

lines 47-49:
  47     if [ -z "$ELEMENT" ]; then
  48      ELEMENT=.
  49     fi

I've never heard of somebody's path including an empty string; this only
triggers on a path like PATH="/usr/local/bin:'':/usr/bin."  I think
this is another misunderstanding of Bourne shell tokenization.  The only
other application I can see for this would be if Bourne interpreted a
PATH="/usr/local/bin::/usr/bin" as having the tokens '/usr/local/bin'
and '' and '/usr/bin' (which it does not), in which case there would be
an empty token, but why should that be interpreted as the current
directory?

In the event there IS an empty string in handed to the loop on line 46,
nothing will happen unless the argument ("$PROGRAM") happens to exist as
a file in / with executable permissions (assuming you remove lines
47-49, otherwise it searches the current directory).

If you really want to be able to handle a corner case like that, add a
third test to line 57 (line 43 on my patched version) to test for
'[ -n "$ELEMENT" ]' (sans single-quotes).  This goes third so that it is
never used except in these rare corner cases (due to short circuiting).



--- which.dpkg  2007-09-30 09:31:40.000000000 -0400
+++ which       2007-11-28 17:23:45.647330496 -0500
@@ -27,10 +27,6 @@
 else
  ALLRET=0
 fi
-case $PATH in
- *::) : "not *DIR:" ;;
-  *:) PATH="$PATH:" ;;
-esac
 for PROGRAM in "$@"; do
  RET=1
  IFS_SAVE="$IFS"
@@ -44,9 +40,6 @@
    ;;
   *)
    for ELEMENT in $PATH; do
-    if [ -z "$ELEMENT" ]; then
-     ELEMENT=.
-    fi
     if [ -f "$ELEMENT/$PROGRAM" ] && [ -x "$ELEMENT/$PROGRAM" ]; then
      puts "$ELEMENT/$PROGRAM"
      RET=0



-- System Information:
Debian Release: lenny/sid
  APT prefers testing
  APT policy: (995, 'testing'), (500, 'testing'), (500, 'stable'), (50, 
'unstable')
Architecture: i386 (i686)

Kernel: Linux 2.6.18-4-686 (SMP w/1 CPU core)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages debianutils depends on:
ii  libc6                         2.6.1-1+b1 GNU C Library: Shared libraries

debianutils recommends no packages.

-- no debconf information



--- End Message ---
--- Begin Message ---
Source: debianutils
Source-Version: 2.28.1

We believe that the bug you reported is fixed in the latest version of
debianutils, which is due to be installed in the Debian FTP archive:

debianutils_2.28.1.dsc
  to pool/main/d/debianutils/debianutils_2.28.1.dsc
debianutils_2.28.1.tar.gz
  to pool/main/d/debianutils/debianutils_2.28.1.tar.gz
debianutils_2.28.1_i386.deb
  to pool/main/d/debianutils/debianutils_2.28.1_i386.deb



A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to [EMAIL PROTECTED],
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Clint Adams <[EMAIL PROTECTED]> (supplier of updated debianutils package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [EMAIL PROTECTED])


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Format: 1.7
Date: Tue, 04 Dec 2007 18:24:07 -0500
Source: debianutils
Binary: debianutils
Architecture: source i386
Version: 2.28.1
Distribution: unstable
Urgency: low
Maintainer: Clint Adams <[EMAIL PROTECTED]>
Changed-By: Clint Adams <[EMAIL PROTECTED]>
Description: 
 debianutils - Miscellaneous utilities specific to Debian
Closes: 453345
Changes: 
 debianutils (2.28.1) unstable; urgency=low
 .
   * which: make case statement more concise as per suggestion of
     Adam Katz.  closes: #453345.
Files: 
 215082aefaebe46800f491d374bd547a 618 utils required debianutils_2.28.1.dsc
 a6440c8ad86abe8bd41187388b25e280 138161 utils required 
debianutils_2.28.1.tar.gz
 fc3cfb4b35209ad349572ba5d23b7713 54818 utils required 
debianutils_2.28.1_i386.deb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Debian!

iD8DBQFHVeQj5m0u66uWM3ARAkKAAKCiVotG69DAHGthrG5sPuBeG/e2lQCgyalG
X+6jLEbZyt7eoWMpboQgl8c=
=g4aV
-----END PGP SIGNATURE-----



--- End Message ---

Reply via email to