aboutsummaryrefslogtreecommitdiffstats
path: root/URPM.xs
diff options
context:
space:
mode:
authorThierry Vignaud <tv@mageia.org>2013-01-20 21:07:43 +0000
committerThierry Vignaud <tv@mageia.org>2013-01-20 21:07:43 +0000
commitc93e7a95b17d143a9e0ef2f8cd55d577cd9bf80f (patch)
tree18660c7dcf574abccbacd14d7f7fc3e3fc6412d3 /URPM.xs
parent0467b3fa3b425dd9fb530f94fd438db87cdb0755 (diff)
downloadperl-URPM-c93e7a95b17d143a9e0ef2f8cd55d577cd9bf80f.tar
perl-URPM-c93e7a95b17d143a9e0ef2f8cd55d577cd9bf80f.tar.gz
perl-URPM-c93e7a95b17d143a9e0ef2f8cd55d577cd9bf80f.tar.bz2
perl-URPM-c93e7a95b17d143a9e0ef2f8cd55d577cd9bf80f.tar.xz
perl-URPM-c93e7a95b17d143a9e0ef2f8cd55d577cd9bf80f.zip
add comments
Diffstat (limited to 'URPM.xs')
-rw-r--r--URPM.xs2
1 files changed, 2 insertions, 0 deletions
diff --git a/URPM.xs b/URPM.xs
index c3f6900..8f19511 100644
--- a/URPM.xs
+++ b/URPM.xs
@@ -1035,6 +1035,7 @@ parse_line(AV *depslist, HV *provides, HV *obsoletes, URPM__Package pkg, char *b
if (obsoletes) update_obsoletes(_pkg, obsoletes);
av_push(depslist, sv_pkg);
}
+ // reset package, next line will be for another one
memset(pkg, 0, sizeof(struct s_Package));
} else if (!strcmp(tag, "filesize"))
pkg->filesize = atoi(data);
@@ -2829,6 +2830,7 @@ Urpm_parse_synthesis__XS(urpm, filename, ...)
f = Fopen(filename, "r.fdio");
if (!rc && (f = Fdopen(f, t)) != NULL && !Ferror(f)) {
+ // initialize first package
memset(&pkg, 0, sizeof(struct s_Package));
buff[sizeof(buff)-1] = 0;
p = buff;