Email List: Xaustin-review-lX
[All Lists]

Defect in XCU diff -r (symlink loops)

To: yyyyyyyyyyyyyyy@xxxxxxxxxxxxx
Subject: Defect in XCU diff -r (symlink loops)
From: yyyyyy@xxxxxxxxxxx
Date: Tue, 13 Jun 2006 07:23:24 +0100 (BST)
        Defect report from : Paul Eggert , UCLA

(Please direct followup comments direct to yyyyyyyyyyyyyy@xxxxxxxxxxxxx)

@ page 319 line 12317 section diff -r (symlink loops) objection {20060612c}

Problem:

Edition of Specification (Year): 2004

Defect code :  1. Error

POSIX currently prevents diff from early discovery of infinite loops
due to symbolic links to directories.

For example, suppose we execute this script:

   mkdir d1 d2
   ln -s . d1/self
   ln -s . d2/self
   diff -r d1 d2

POSIX currently requires behavior something like this:

   Common subdirectories: d1/self and d2/self
   Common subdirectories: d1/self/self and d2/self/self
   Common subdirectories: d1/self/self/self and d2/self/self/self
   ...
   diff: d1/self/self/.../self: Number of symbolic links encountered during 
path name traversal exceeds MAXSYMLINKS

But the following behavior is more useful, and POSIX should allow it:

   diff: d1/self: recursive directory loop


Action:

After XCU page 319 line 12317 (diff -r) insert the following text:

   If the recursion encounters a recursive directory loop (e.g., due
   to a symbolic link to a parent directory), the behavior is
   implementation-defined.

<Prev in Thread] Current Thread [Next in Thread>
  • Defect in XCU diff -r (symlink loops), eggert <=