diff options
author | Dan McGee <dan@archlinux.org> | 2010-12-14 19:06:31 +0100 |
---|---|---|
committer | Dan McGee <dan@archlinux.org> | 2010-12-14 19:06:31 +0100 |
commit | c2a73ba989fffb59c1b8ac7edb265a996dfc184d (patch) | |
tree | eb1e648f4e011f4ef49a836c9d81f123dc347313 /lib/libalpm/be_package.c | |
parent | dbf59a6b141213b0afc962c71347eb83f8bcab73 (diff) | |
download | pacman-c2a73ba989fffb59c1b8ac7edb265a996dfc184d.tar.gz pacman-c2a73ba989fffb59c1b8ac7edb265a996dfc184d.tar.xz |
When setting package name, set hash value as well
Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'lib/libalpm/be_package.c')
-rw-r--r-- | lib/libalpm/be_package.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/libalpm/be_package.c b/lib/libalpm/be_package.c index ae951945..32ec9934 100644 --- a/lib/libalpm/be_package.c +++ b/lib/libalpm/be_package.c @@ -179,6 +179,7 @@ static int parse_descfile(struct archive *a, pmpkg_t *newpkg) ptr = _alpm_strtrim(ptr); if(strcmp(key, "pkgname") == 0) { STRDUP(newpkg->name, ptr, RET_ERR(PM_ERR_MEMORY, -1)); + newpkg->name_hash = _alpm_hash_sdbm(newpkg->name); } else if(strcmp(key, "pkgver") == 0) { STRDUP(newpkg->version, ptr, RET_ERR(PM_ERR_MEMORY, -1)); } else if(strcmp(key, "pkgdesc") == 0) { |