summaryrefslogtreecommitdiffstats
path: root/libopkg
diff options
context:
space:
mode:
authorgraham.gower <graham.gower@e8e0d7a0-c8d9-11dd-a880-a1081c7ac358>2009-11-05 23:27:37 (EST)
committer graham.gower <graham.gower@e8e0d7a0-c8d9-11dd-a880-a1081c7ac358>2009-11-05 23:27:37 (EST)
commit4a1946ab90b3b98c1362e0fc366867bd56418bf9 (patch)
tree94f60b66d7d21b36ce3316c07e59abb0518b810c /libopkg
parenta6502c7951410e25df67c621165581ebd99fbb0f (diff)
Remove dead code. We would segfault before following this code path.
git-svn-id: http://opkg.googlecode.com/svn/trunk@267 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
Diffstat (limited to 'libopkg')
-rw-r--r--libopkg/opkg_install.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/libopkg/opkg_install.c b/libopkg/opkg_install.c
index a67129e..b3ece9c 100644
--- a/libopkg/opkg_install.c
+++ b/libopkg/opkg_install.c
@@ -581,14 +581,13 @@ static int pkg_remove_orphan_dependent(opkg_conf_t *conf, pkg_t *pkg, pkg_t *old
int i, j, found;
char *buf, *d_str;
pkg_t *p;
+
if (!old_pkg)
return 0;
- if (!pkg) {
- fprintf(stderr, "pkg shall not be NULL here. please send to the bugzilla!! [%s %d]\n", __FILE__, __LINE__);
- return -1;
- }
+
if (old_pkg->depends_count == 0)
return 0;
+
for (i=0;i<old_pkg->depends_count;i++) {
found = 0;
for (j=0;j<pkg->depends_count;j++) {