Author: guillem
Date: 2006-06-04 15:42:01 +0000 (Sun, 04 Jun 2006)
New Revision: 376

Modified:
   trunk/ChangeLog
   trunk/debian/changelog
   trunk/src/depcon.c
Log:
Fix dependency cycle breaking in the case when every link involves
a Provides (Ian Jackson). This is a proper fix for #349442.
Closes: #370017


Modified: trunk/ChangeLog
===================================================================
--- trunk/ChangeLog     2006-06-04 12:24:47 UTC (rev 375)
+++ trunk/ChangeLog     2006-06-04 15:42:01 UTC (rev 376)
@@ -1,3 +1,12 @@
+2006-06-04  Ian Jackson  <[EMAIL PROTECTED]>
+
+       * src/depcon.c (foundcyclebroken): Replace possi->ed argument to
+       findbreakcyclerecursive call with dependedon.
+       (findbreakcyclerecursive): Remove the last foundcyclebroken call
+       which was wrongly using the unrelated provider->installed.depended
+       linked list. Remove findbreakcyclerecursive call which may lead to
+       infinite recursion.
+
 2006-06-04  Guillem Jover  <[EMAIL PROTECTED]>
 
        * scripts/dpkg-parsechangelog.pl: Pass forward the '-l' option to

Modified: trunk/debian/changelog
===================================================================
--- trunk/debian/changelog      2006-06-04 12:24:47 UTC (rev 375)
+++ trunk/debian/changelog      2006-06-04 15:42:01 UTC (rev 376)
@@ -10,6 +10,9 @@
     Closes: #369928, #369958, #370157, #370174, #370210
   * Print the correct file being parsed by dpkg-parsechangelog's debian
     parser. Closes: #368961
+  * Fix dependency cycle breaking in the case when every link involves
+    a Provides (Ian Jackson). This is a proper fix for #349442.
+    Closes: #370017
 
   [ Updated dpkg Translations ]
   * Czech (Miroslav Kure).

Modified: trunk/src/depcon.c
===================================================================
--- trunk/src/depcon.c  2006-06-04 12:24:47 UTC (rev 375)
+++ trunk/src/depcon.c  2006-06-04 15:42:01 UTC (rev 376)
@@ -56,7 +56,8 @@
   for (sol=sofar; sol && sol->pkg != dependedon; sol=sol->back);
 
   /* If not, we do a recursive search on it to see what we find. */
-  if (!sol) return findbreakcyclerecursive(possi->ed,thislink);
+  if (!sol)
+    return findbreakcyclerecursive(dependedon, thislink);
   
   debug(dbg_depcon,"found cycle");
   /* Right, we now break one of the links.  We prefer to break
@@ -126,8 +127,6 @@
          * still the one we use.
          */
         if (foundcyclebroken(&thislink,sofar,provider,possi)) return 1;
-       if 
(foundcyclebroken(&thislink,sofar,possi->ed,provider->installed.depended)) 
return 1;
-       if (findbreakcyclerecursive(provider,&thislink)) return 1;
       }
     }
   }


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

Reply via email to