May be it is sufficient to have name indexes for provides and requires...
The patch requires the other one.

Florian

>From e688ddb94a39933c8fc0bad96b5bad53da23f88d Mon Sep 17 00:00:00 2001
From: Florian Festi <[EMAIL PROTECTED]>
Date: Thu, 23 Aug 2007 13:57:35 +0200
Subject: [PATCH] Create name indexes only for provides and requires

---
 db.c |   16 +++++++++-------
 1 files changed, 9 insertions(+), 7 deletions(-)

diff --git a/db.c b/db.c
index b31a79b..e69ebc5 100644
--- a/db.c
+++ b/db.c
@@ -435,13 +435,15 @@ yum_db_create_primary_tables (sqlite3 *db, GError **err)
             return;
         }
 
-        query = g_strdup_printf(nameindexsql, deps[i], deps[i]);
-        rc = sqlite3_exec (db, sql, NULL, NULL, NULL);
-        if (rc != SQLITE_OK) {
-            g_set_error (err, YUM_DB_ERROR, YUM_DB_ERROR,
-                         "Can not create %sname index: %s",
-                         deps[i], sqlite3_errmsg (db));
-            return;
+        if (i < 2) {
+            query = g_strdup_printf(nameindexsql, deps[i], deps[i]);
+            rc = sqlite3_exec (db, sql, NULL, NULL, NULL);
+            if (rc != SQLITE_OK) {
+                g_set_error (err, YUM_DB_ERROR, YUM_DB_ERROR,
+                             "Can not create %sname index: %s",
+                             deps[i], sqlite3_errmsg (db));
+                return;
+            }
         }
 
     }
-- 
1.5.2.2

_______________________________________________
Yum-devel mailing list
[email protected]
https://lists.dulug.duke.edu/mailman/listinfo/yum-devel

Reply via email to