=== modified file 'apt-pkg/packagemanager.cc'
--- apt-pkg/packagemanager.cc	2012-05-05 13:37:31 +0000
+++ apt-pkg/packagemanager.cc	2012-05-19 21:07:30 +0000
@@ -785,7 +785,7 @@
 			   VerIterator V(Cache,*I);
 			   PkgIterator P = V.ParentPkg();
 			   // we are checking for installation as an easy 'protection' against or-groups and (unchosen) providers
-			   if (P->CurrentVer == 0 || P != Pkg || (P.CurrentVer() != V && Cache[P].InstallVer != V))
+			   if (P != Pkg || (P.CurrentVer() != V && Cache[P].InstallVer != V))
 			      continue;
 			   circle = true;
 			   break;

=== modified file 'debian/changelog'
--- debian/changelog	2012-05-19 16:38:27 +0000
+++ debian/changelog	2012-05-19 21:07:30 +0000
@@ -33,6 +33,8 @@
       to get the correct section titles provided by docbook
   * doc/po/de.po:
     - updated german manpage translation by Chris Leick, thanks!
+  * apt-pkg/packagemanager.cc:
+    - do not run into loop on new-pre-depends-breaks (Closes: #673536)
 
   [ Raphael Geissert ]
   * apt-pkg/acquire*.cc:

=== added file 'test/integration/test-673536-pre-depends-breaks-loop'
--- test/integration/test-673536-pre-depends-breaks-loop	1970-01-01 00:00:00 +0000
+++ test/integration/test-673536-pre-depends-breaks-loop	2012-05-19 21:07:30 +0000
@@ -0,0 +1,23 @@
+#!/bin/sh
+set -e
+
+TESTDIR=$(readlink -f $(dirname $0))
+. $TESTDIR/framework
+setupenvironment
+configarchitecture 'native'
+
+buildsimplenativepackage 'basic' 'native' '1' 'stable'
+buildsimplenativepackage 'basic' 'native' '2' 'unstable' 'Pre-Depends: common'
+buildsimplenativepackage 'common' 'native' '2' 'unstable' 'Breaks: basic (<= 1)'
+
+setupaptarchive
+
+# we check with 'real' packages here as the simulation reports a 'Conf broken'
+# which is technical correct for the simulation, but testing errormsg is ugly
+
+aptget install basic=1 -qq > /dev/null
+testdpkginstalled basic
+testdpkgnotinstalled common
+
+aptget dist-upgrade -qq > /dev/null
+testdpkginstalled basic common

