Hello,

I made myself unclear earlier.  I have been submitting a patch for this
problem for some time now, but forgot to include it in my renewed request
for consideration.

This absolutely a failure of functionality, and not a "feature"
admissable to control by (yet another) command line option.  The program
already has a command line option which says to follow symlinks, and
therefore implies that it does not follow symlinks when that option is
not specified.  This is true for regular files.  However, it is not true
for directories.

Here is the patch for the cdrtools-1.11a14 version of mkisofs/mkisofs.c.

Thanks,

/ken

--- mkisofs.c-orig      Sun Feb 10 11:35:20 2002
+++ mkisofs.c   Tue Feb 12 10:42:17 2002
@@ -2563,7 +2563,15 @@
                 * Now see whether the user wants to add a regular file, or a
                 * directory at this point.
                 */
-               status = stat_filter(node, &st);
+
+               status = lstat_filter(node, &st);
+
+               if (status == 0
+                   && S_ISLNK(statbuf.st_mode)
+                   && follow_links) {
+                 status = stat_filter(node, &st);
+               }
+
                if (status != 0) {
                        /*
                         * This is a fatal error - the user won't be getting


------- Start of forwarded message -------
To: [EMAIL PROTECTED], [EMAIL PROTECTED]
Subject:  Re: mkisofs bug with -graft-points and symlinks
Date: Mon, 11 Feb 2002 13:21:17 -0800 (PST)
From: [EMAIL PROTECTED] (ken dawson chia wu)

Hello,

I was advised to hold my enthusiasm for this issue because the developer
was working hard on cdrecord.  I  have done so.  But now that the release
of cdrtools-1.11a14 shows activity in mkisofs (though not in mkisofs.c),
I renew my claim that if symlinks with graftpoints do not work properly,
mkisofs does not produce correct backups.

This really should be fixed.

/ken

Date: Mon, 23 Apr 2001 12:44:19 -0700 (PDT)
X-Authentication-Warning: k3n.eng.sun.com: kend set sender to [EMAIL PROTECTED] 
using -f
From: Ken Dawson <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
CC: [EMAIL PROTECTED]
In-reply-to: <[EMAIL PROTECTED]> (message from Joerg
        Schilling on Mon, 23 Apr 2001 21:02:37 +0200 (MET DST))
Subject: Re: mkisofs 1.13 bug with -graft-points and symlinks
Content-Length: 4218

] Date: Mon, 23 Apr 2001 21:02:37 +0200 (MET DST)
] From: Joerg Schilling <[EMAIL PROTECTED]>
] To: [EMAIL PROTECTED]
] Subject: Re: mkisofs 1.13 bug with -graft-points and symlinks
] Content-Length: 975
] 
] >From [EMAIL PROTECTED] Mon Apr 23 21:00:51 2001
] 
] >I believe that I am encountering a misbehavior in mkisofs when
] >-graft-points is used in conjunction with symbolic links in the path
] >list.
] 
] >I am attempting to backup a Slackware installation, and in that
] >distribution, they have the following:
] 
] >    /usr:
] >    lrwxrwxrwx   1 root     root            5 Jul 18  2000 X11 -> X11R6/
] >    drwxr-xr-x  12 root     root         4096 Oct 23  2000 X11R6/
] 
] >I try to execute the command:
] 
] >    mkisofs -o test.iso -R -graft-points /usr/X11=/usr/X11 /usr/X11R6/=/usr/X11R6/
] 
] >with mkisofs version 1.13 (which I got from the cdrecord-1.9 bundle),
] 
] What happens if you use a recent version?

It appears that the warning is no longer fatal, but the image that it
creates is incorrect.

    cd /var/tmp/input/
    bash /var/tmp/input/new-test-command
    Warning: creating filesystem that does not conform to ISO-9660.
    /usr/testsw/cdrtools-1.10/mkisofs/OBJ/i686-linux-cc/mkisofs: Warning: Directory 
loop (/usr/X11R6/lib dev: 302 ino: 130951).
    /usr/testsw/cdrtools-1.10/mkisofs/OBJ/i686-linux-cc/mkisofs: Warning: Directory 
loop (/usr/X11R6/lib/fonts dev: 302 ino: 163685).
    /usr/testsw/cdrtools-1.10/mkisofs/OBJ/i686-linux-cc/mkisofs: Warning: Directory 
loop (/usr/X11R6/lib/fonts/Type1 dev: 302 ino: 590770).

    ...

    Using LIBXX000.A;1 for  /usr/X11/lib/libXxf86dga.a (libXxf86vm.a)
    Using LIBXX001.A;1 for  /usr/X11/lib/libXxf86vm.a (libXxf86misc.a)
    Using LIBME000.SO;1 for  /usr/X11/lib/libMesaGLU.so (libMesaGL.so)
    Using LIBXM000.SO.2;1 for  /usr/X11/lib/libXm.so.2 (libXm.so.1.0.2)
    Using LIBMR000.S.2;1 for  /usr/X11/lib/libMrm.so.2 (libMrm.so.1.0.2)

    ...

    Using XMPUS000.HTM;1 for  /usr/X11R6/LessTif/doc/html/XmPushButtonGadget.html 
(XmPushButton.html)
    Using XMDIA000.HTM;1 for  /usr/X11R6/LessTif/doc/html/XmDialogShellExt.html 
(XmDialogShell.html)
    Using XMCAS000.HTM;1 for  /usr/X11R6/LessTif/doc/html/XmCascadeButtonGadget.html 
(XmCascadeButton.html)
    Using XMARR000.HTM;1 for  /usr/X11R6/LessTif/doc/html/XmArrowButtonGadget.html 
(XmArrowButton.html)
    Using LESST000.PNG;1 for  /usr/X11R6/LessTif/doc/images/lesstif-small.png 
(lesstif-realsmall.png)
      8.66% done, estimate finish Mon Apr 23 12:26:53 2001
     17.30% done, estimate finish Mon Apr 23 12:27:16 2001
     25.95% done, estimate finish Mon Apr 23 12:27:59 2001
     34.61% done, estimate finish Mon Apr 23 12:28:02 2001
     43.24% done, estimate finish Mon Apr 23 12:27:53 2001
     51.88% done, estimate finish Mon Apr 23 12:27:45 2001
     60.54% done, estimate finish Mon Apr 23 12:27:39 2001
     69.19% done, estimate finish Mon Apr 23 12:27:36 2001
     77.84% done, estimate finish Mon Apr 23 12:27:37 2001
     86.47% done, estimate finish Mon Apr 23 12:27:57 2001
     95.12% done, estimate finish Mon Apr 23 12:27:55 2001
    Total translation table size: 0
    Total rockridge attributes bytes: 1088253
    Total directory bytes: 1079296
    Path table size(bytes): 4812
    Max brk space used 4e9000
    57824 extents written (112 Mb)


Here's an ls -f from the file test.iso

    /mnt:
    total 2
    dr-xr-xr-x  13 root     root         2048 Apr 23 12:26 usr/

    /mnt/usr:
    total 84
    drwxr-xr-x   3 root     root         2048 May 31  2000 GNUstep/
    drwxr-xr-x   5 root     root         2048 Feb 26  2000 LessTif/
    dr-xr-xr-x  12 root     root         2048 Apr 23 12:26 X11R6/
    drwxr-xr-x   2 root     bin         45056 Apr 29  1994 bin/
    drwxr-xr-x   3 root     root         2048 May 28  2000 etc/
    drwxr-xr-x   5 root     root         2048 Oct 23  2000 include/
    drwxr-xr-x   2 root     root         2048 Aug  4  1999 info/
    drwxr-xr-x   9 root     root        18432 Apr 10  1997 lib/
    drwxr-xr-x   3 root     root         2048 Jun  2  2000 libexec/
    drwxr-xr-x  12 root     root         4096 Aug  7  1995 man/
    drwxr-xr-x  10 root     root         2048 May 16  2000 share/

    ...

/ken
------- End of forwarded message -------


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

Reply via email to