Package: dpsyco-lib
Version: 1.0.33
Severity: normal
File: /usr/bin/dpsyco-applypatch


Hello,
while I'm reading scripts to understand dpsyco I found a small typo:

--- /usr/bin/dpsyco-applypatch  2007-03-02 05:26:23.000000000 +0100
+++ /tmp/dpsyco-applypatch      2007-03-19 17:40:40.000000000 +0100
@@ -30,11 +30,11 @@
 DESTR="$2"
 PATCHOPT="$3"
 
-if [ -z "PF" ] ; then
+if [ -z "$PF" ] ; then
     echo "No patch file specified, exiting."
     exit 0
 fi
-if [ -z "DESTR" ] ; then
+if [ -z "$DESTR" ] ; then
     echo "No destination specified, exiting."
     exit 0
 fi

When I saw following line in /usr/bin/dpsyco-patch

    DESTAPP=$(echo "$DEST" | sed -e "s|^/||;")

IMHO I think it could be better to write

    DESTAPP=$(echo "$DEST" | sed -e "s|^//*||;")

bacause filename can contain duplicate `/' in itself, when someone
(me :-) is lazy to normalize it (e.g. ///bin//sh is valid path).
A bit paranoid :-)
Regards
--
Vaclav Ovsik


-- System Information:
Debian Release: 4.0
  APT prefers testing
  APT policy: (500, 'testing')
Architecture: i386 (i686)
Shell:  /bin/sh linked to /bin/bash
Kernel: Linux 2.6.18-4-xen-686
Locale: LANG=C, LC_CTYPE=cs_CZ.ISO-8859-2 (charmap=ISO-8859-2)

Versions of packages dpsyco-lib depends on:
ii  adduser                       3.102      Add and remove users and groups
ii  rsync                         2.6.9-2    fast remote file copy program (lik

dpsyco-lib recommends no packages.

-- no debconf information


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to