summaryrefslogtreecommitdiff
path: root/src/repodata.c
diff options
context:
space:
mode:
authorMichael Schroeder <mls@suse.de>2011-04-04 16:26:56 +0200
committerMichael Schroeder <mls@suse.de>2011-04-04 16:26:56 +0200
commit2b784d3aa34cdf77b0374735fa7460b498cacb6c (patch)
treecfbb97bb5454fdf170039f52038570ccb3f04d7d /src/repodata.c
parenteb1db882718c79c8f21117d53adcee4057fbc18d (diff)
downloadlibsolv-2b784d3aa34cdf77b0374735fa7460b498cacb6c.tar.gz
libsolv-2b784d3aa34cdf77b0374735fa7460b498cacb6c.tar.bz2
libsolv-2b784d3aa34cdf77b0374735fa7460b498cacb6c.zip
- fix constantid handling for localpool case: we must treat constantid the same as a normal id, so it must not be mapped to the pool
Diffstat (limited to 'src/repodata.c')
-rw-r--r--src/repodata.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/repodata.c b/src/repodata.c
index 4246ee3..7231c03 100644
--- a/src/repodata.c
+++ b/src/repodata.c
@@ -611,13 +611,13 @@ repodata_lookup_str(Repodata *data, Id solvid, Id keyname)
if (key->type == REPOKEY_TYPE_STR)
return (const char *)dp;
if (key->type == REPOKEY_TYPE_CONSTANTID)
- return id2str(data->repo->pool, key->size);
- if (key->type == REPOKEY_TYPE_ID)
+ id = key->size;
+ else if (key->type == REPOKEY_TYPE_ID)
dp = data_read_id(dp, &id);
else
return 0;
if (data->localpool)
- return data->spool.stringspace + data->spool.strings[id];
+ return stringpool_id2str(&data->spool, id);
return id2str(data->repo->pool, id);
}