diff options
author | pixdamix <pixdamix@e8e0d7a0-c8d9-11dd-a880-a1081c7ac358> | 2009-11-02 10:47:29 (EST) |
---|---|---|
committer | pixdamix <pixdamix@e8e0d7a0-c8d9-11dd-a880-a1081c7ac358> | 2009-11-02 10:47:29 (EST) |
commit | d47d475e70c13208bc3f61997943c65bbfbe132f (patch) | |
tree | 440002cfa3ed6eb40193010f177c7df71f1c7c7a /libopkg | |
parent | 93e1d91434de59ba4bad8238e03b7ef8e3ed43ba (diff) |
opkg: fix nullpointer dereference
Applied 011-fix_nullpointer_deref.patch from OpenWRT
git-svn-id: http://opkg.googlecode.com/svn/trunk@240 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
Diffstat (limited to 'libopkg')
-rw-r--r-- | libopkg/opkg_cmd.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libopkg/opkg_cmd.c b/libopkg/opkg_cmd.c index 99ee64d..d9ad77a 100644 --- a/libopkg/opkg_cmd.c +++ b/libopkg/opkg_cmd.c @@ -951,7 +951,7 @@ static int opkg_remove_cmd(opkg_conf_t *conf, int argc, char **argv) pkg_to_remove = pkg_hash_fetch_installed_by_name(&conf->pkg_hash, pkg->name ); } - if (pkg == NULL) { + if (pkg_to_remove == NULL) { opkg_message(conf, OPKG_ERROR, "Package %s is not installed.\n", pkg->name); continue; } |