summaryrefslogtreecommitdiff
path: root/src/repo_solv.c
diff options
context:
space:
mode:
authorMichael Schroeder <mls@suse.de>2008-03-19 21:19:34 +0000
committerMichael Schroeder <mls@suse.de>2008-03-19 21:19:34 +0000
commitbd37323a54c95e5fbb7eb5b2f6ad270b50b3a513 (patch)
treea5d255730105a6f75912012c1bcaa3860acbc76f /src/repo_solv.c
parenta953e39aa513bb10faa23a03a7befa1de29f54e7 (diff)
downloadlibsolv-bd37323a54c95e5fbb7eb5b2f6ad270b50b3a513.tar.gz
libsolv-bd37323a54c95e5fbb7eb5b2f6ad270b50b3a513.tar.bz2
libsolv-bd37323a54c95e5fbb7eb5b2f6ad270b50b3a513.zip
- beautify add_array code
- fix bugs and a memory leak in addfileprovides
Diffstat (limited to 'src/repo_solv.c')
-rw-r--r--src/repo_solv.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/repo_solv.c b/src/repo_solv.c
index 8dfcc76..11767e8 100644
--- a/src/repo_solv.c
+++ b/src/repo_solv.c
@@ -1347,9 +1347,11 @@ fprintf(stderr, "solv %d name %d type %d class %d\n", i, id, keys[key].type, key
{
dps = dp;
dp = data_skip(dp, REPOKEY_TYPE_IDARRAY);
- if (keys[key].storage == KEY_STORAGE_INCORE && idmap)
+ if (keys[key].storage != KEY_STORAGE_INCORE)
+ break;
+ if (idmap)
incore_map_idarray(&data, dps, idmap, numid);
- else if (keys[key].storage == KEY_STORAGE_INCORE)
+ else
incore_add_blob(&data, dps, dp - dps);
break;
}