Mailinglist Archive: opensuse-commit (1028 mails)

< Previous Next >
commit libzypp-zmd-backend
  • From: root@xxxxxxx (h_root)
  • Date: Tue, 6 Jun 2006 22:25:04 +0200 (CEST)
  • Message-id: <20060606202504.5E6369422C@xxxxxxxxxxxxxxx>

Hello community,

here is the log from the commit of package libzypp-zmd-backend
checked in at Tue Jun 6 22:25:04 CEST 2006.

--------
--- libzypp-zmd-backend/libzypp-zmd-backend.changes 2006-06-02 15:31:40.000000000 +0200
+++ libzypp-zmd-backend/libzypp-zmd-backend.changes 2006-06-06 13:42:25.000000000 +0200
@@ -1,0 +2,6 @@
+Tue Jun 6 13:10:10 CEST 2006 - kkaempf@xxxxxxx
+
+- empty catalog before filling (#181602)
+- rev 3510
+
+-------------------------------------------------------------------

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ libzypp-zmd-backend.spec ++++++
--- /var/tmp/diff_new_pack.CsaLXR/_old 2006-06-06 22:24:58.000000000 +0200
+++ /var/tmp/diff_new_pack.CsaLXR/_new 2006-06-06 22:24:58.000000000 +0200
@@ -22,7 +22,7 @@
Obsoletes: zmd-librc-backend
Summary: ZMD backend for Package, Patch, Pattern, and Product Management
Version: 7.1.1.0
-Release: 52
+Release: 53
Source: zmd-backend-%{version}.tar.bz2
Prefix: /usr

@@ -68,6 +68,9 @@
/etc/logrotate.d/zmd-backend

%changelog -n libzypp-zmd-backend
+* Tue Jun 06 2006 - kkaempf@xxxxxxx
+- empty catalog before filling (#181602)
+- rev 3510
* Fri Jun 02 2006 - kkaempf@xxxxxxx
- refresh all remote zypp-owned sources. Not just those added
via YaST but also added via rug (#181182)

++++++ zmd-backend-7.1.1.0.tar.bz2 ++++++
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/zmd-backend-7.1.1.0/src/dbsource/DbAccess.cc new/zmd-backend-7.1.1.0/src/dbsource/DbAccess.cc
--- old/zmd-backend-7.1.1.0/src/dbsource/DbAccess.cc 2006-05-17 10:03:18.000000000 +0200
+++ new/zmd-backend-7.1.1.0/src/dbsource/DbAccess.cc 2006-06-06 13:06:45.000000000 +0200
@@ -1084,6 +1084,30 @@
}


+/** empty catalog, remove all resolvables belonging to this catalog */
+/* parameter 'const char ** because of callers */
+bool
+DbAccess::emptyCatalog( const char *catalog )
+{
+ string query ("DELETE FROM resolvables where catalog = ? ");
+
+ sqlite3_stmt *handle = prepare_handle( _db, query );
+ if (handle == NULL) {
+ return false;
+ }
+
+ sqlite3_bind_text( handle, 1, catalog, -1, SQLITE_STATIC );
+
+ int rc = sqlite3_step( handle);
+ if (rc != SQLITE_DONE) {
+ ERR << "rc " << rc << ", Error emptying catalog: " << sqlite3_errmsg (_db) << endl;
+ }
+ sqlite3_reset( handle);
+
+ return (rc == SQLITE_DONE);
+}
+
+
//----------------------------------------------------------------------------
// store

@@ -1097,6 +1121,8 @@
return;
}

+ emptyCatalog( catalog );
+
Arch sysarch = getZYpp()->architecture();

int count = 0;
@@ -1141,6 +1167,8 @@
return;
}

+ emptyCatalog( catalog );
+
int count = 0;
sqlite_int64 rowid = 0;
for (ResPool::const_iterator iter = pool.begin(); iter != pool.end(); ++iter) {
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/zmd-backend-7.1.1.0/src/dbsource/DbAccess.h new/zmd-backend-7.1.1.0/src/dbsource/DbAccess.h
--- old/zmd-backend-7.1.1.0/src/dbsource/DbAccess.h 2006-05-16 11:18:28.000000000 +0200
+++ new/zmd-backend-7.1.1.0/src/dbsource/DbAccess.h 2006-06-06 13:06:03.000000000 +0200
@@ -199,6 +199,8 @@
bool removeCatalog( const std::string & catalog );
/** update catalog, update all non-empty parameters (name, alias, description) */
bool updateCatalog( const std::string & catalog, const std::string & name, const std::string & alias, const std::string & description );
+ /** empty catalog, remove all resolvables belonging to this catalog */
+ bool emptyCatalog( const char *catalog );

/** write resolvables from store to db */
void writeStore( const zypp::ResStore & resolvables, zypp::ResStatus status, const char *catalog = NULL, Ownership owner = ZYPP_OWNED );


++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++



Remember to have fun...


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

< Previous Next >