diff options
author | Per Øyvind Karlsen <peroyvind@mandriva.org> | 2011-05-03 16:59:55 +0000 |
---|---|---|
committer | Per Øyvind Karlsen <peroyvind@mandriva.org> | 2011-05-03 16:59:55 +0000 |
commit | 1c041874ad9f96a0cf8a6382482234f5ea76c5e7 (patch) | |
tree | 39981a635a56f3f9567788037d5ff24154f7a70b | |
parent | 74302a4e7a0160f4e2af17a6662c5eac572fcf3d (diff) | |
download | perl-URPM-1c041874ad9f96a0cf8a6382482234f5ea76c5e7.tar perl-URPM-1c041874ad9f96a0cf8a6382482234f5ea76c5e7.tar.gz perl-URPM-1c041874ad9f96a0cf8a6382482234f5ea76c5e7.tar.bz2 perl-URPM-1c041874ad9f96a0cf8a6382482234f5ea76c5e7.tar.xz perl-URPM-1c041874ad9f96a0cf8a6382482234f5ea76c5e7.zip |
fix some invalid free()'s
-rw-r--r-- | NEWS | 4 | ||||
-rw-r--r-- | URPM.pm | 2 | ||||
-rw-r--r-- | URPM.xs | 14 |
3 files changed, 12 insertions, 8 deletions
@@ -1,3 +1,7 @@ +Version 4.25 - May 2011, by Per Øyvind Karlsen + +- fix some invalid free()'s + Version 4.24 - 3 May 2011, by Per Øyvind Karlsen - fix segfault caused by attempting to assign arch of wrong package @@ -11,7 +11,7 @@ use URPM::Resolve; use URPM::Signature; our @ISA = qw(DynaLoader); -our $VERSION = '4.24'; +our $VERSION = '4.25'; URPM->bootstrap($VERSION); @@ -2279,11 +2279,11 @@ Pkg_compare_pkg(lpkg, rpkg) URPM::Package rpkg PREINIT: int compare = 0; - char *levr; - char *larch; - char *revr; - char *rarch; - char *tmp; + char *levr = NULL; + char *larch = NULL; + char *revr = NULL; + char *rarch = NULL; + char *tmp = NULL; CODE: if (lpkg == rpkg) RETVAL = 0; else { @@ -2337,8 +2337,8 @@ Pkg_compare_pkg(lpkg, rpkg) compare = rscore - lscore; /* score are lower for better */ } } - if (!lpkg->info) _free(larch); - if (!rpkg->info) _free(rarch); + if (!lpkg->info) larch = _free(larch); + if (!rpkg->info) rarch = _free(rarch); restore_chars(); RETVAL = compare; } |