Mailinglist Archive: zypp-commit (301 mails)

< Previous Next >
[zypp-commit] r7444 - in /trunk/libzypp: package/libzypp.changes zypp/parser/plaindir/RepoParser.cc
  • From: aschnell@xxxxxxxxxxxxxxxx
  • Date: Fri, 05 Oct 2007 08:52:40 -0000
  • Message-id: <20071005085241.053BA2FCFD@xxxxxxxxxxxxxxxx>
Author: aschnell
Date: Fri Oct  5 10:52:40 2007
New Revision: 7444

URL: http://svn.opensuse.org/viewcvs/zypp?rev=7444&view=rev
Log:
- filter architecture in plaindir parser (bug #330791)

Modified:
    trunk/libzypp/package/libzypp.changes
    trunk/libzypp/zypp/parser/plaindir/RepoParser.cc

Modified: trunk/libzypp/package/libzypp.changes
URL: http://svn.opensuse.org/viewcvs/zypp/trunk/libzypp/package/libzypp.changes?rev=7444&r1=7443&r2=7444&view=diff
==============================================================================
--- trunk/libzypp/package/libzypp.changes (original)
+++ trunk/libzypp/package/libzypp.changes Fri Oct  5 10:52:40 2007
@@ -1,4 +1,9 @@
 -------------------------------------------------------------------
+Fri Oct 05 10:35:47 CEST 2007 - aschnell@xxxxxxx
+
+- filter architecture in plaindir parser (bug #330791)
+
+-------------------------------------------------------------------
 Thu Oct  4 16:31:58 CEST 2007 - ma@xxxxxxx
 
 - Throw constructing malformed checksums. (#189096)

Modified: trunk/libzypp/zypp/parser/plaindir/RepoParser.cc
URL: http://svn.opensuse.org/viewcvs/zypp/trunk/libzypp/zypp/parser/plaindir/RepoParser.cc?rev=7444&r1=7443&r2=7444&view=diff
==============================================================================
--- trunk/libzypp/zypp/parser/plaindir/RepoParser.cc (original)
+++ trunk/libzypp/zypp/parser/plaindir/RepoParser.cc Fri Oct  5 10:52:40 2007
@@ -161,6 +161,7 @@
           const ProgressData::ReceiverFnc & fnc_r )
     : _repositoryId( repositoryId_r )
     , _consumer( consumer_r )
+    , _sysarch( ZConfig::instance().systemArchitecture() )
     {
       _ticks.sendTo( fnc_r );
     }
@@ -174,6 +175,7 @@
     data::RecordId                 _repositoryId;
     data::ResolvableDataConsumer & _consumer;
     ProgressData                   _ticks;
+    Arch                          _sysarch;
 
   private: // these (and _ticks) are actually scoped per parse() run.
 };
@@ -246,8 +248,15 @@
 #warning FIX creation of Package from src.rpm header
       data::Package_Ptr package = makePackageDataFromHeader( header, NULL, *it, _repositoryId );
       if (package != NULL) {
-        DBG << "Adding package " << *package << endl;
-        _consumer.consumePackage( _repositoryId, package );
+       if (package->arch.compatibleWith(_sysarch))
+       {
+         DBG << "Adding package " << *package << endl;
+         _consumer.consumePackage( _repositoryId, package );
+       }
+       else
+       {
+         DBG << "Ignoring package " << *package << endl;
+       }
       }
     }
   }

--
To unsubscribe, e-mail: zypp-commit+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: zypp-commit+help@xxxxxxxxxxxx

< Previous Next >
This Thread
  • No further messages