aboutsummaryrefslogtreecommitdiffstats
path: root/URPM.xs
diff options
context:
space:
mode:
Diffstat (limited to 'URPM.xs')
-rw-r--r--URPM.xs13
1 files changed, 4 insertions, 9 deletions
diff --git a/URPM.xs b/URPM.xs
index ca66abf..b0ce662 100644
--- a/URPM.xs
+++ b/URPM.xs
@@ -553,8 +553,7 @@ return_list_tag(const URPM__Package pkg, rpmTag tag_name) {
case RPM_INT32_TYPE:
{
int i;
- int *r;
- r = (int *)list;
+ int *r = (int *)list;
for (i=0; i < count; i++) {
mXPUSHs(newSViv(r[i]));
}
@@ -568,12 +567,9 @@ return_list_tag(const URPM__Package pkg, rpmTag tag_name) {
case RPM_STRING_ARRAY_TYPE:
{
int i;
- char **s;
-
- s = (char **)list;
- for (i = 0; i < count; i++) {
+ char **s = (char **)list;
+ for (i = 0; i < count; i++)
mXPUSHs(newSVpv(s[i], 0));
- }
}
break;
case RPM_I18NSTRING_TYPE:
@@ -1890,9 +1886,8 @@ void
Pkg_id(pkg)
URPM::Package pkg
PPCODE:
- if ((pkg->flag & FLAG_ID) <= FLAG_ID_MAX) {
+ if ((pkg->flag & FLAG_ID) <= FLAG_ID_MAX)
mXPUSHs(newSViv(pkg->flag & FLAG_ID));
- }
void
Pkg_set_id(pkg, id=-1)