aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThierry Vignaud <tv@mageia.org>2012-06-13 18:44:00 +0000
committerThierry Vignaud <tv@mageia.org>2012-06-13 18:44:00 +0000
commit0df0d67c963e95cff5c834e2bb016161ec241e54 (patch)
tree8b325a6177ef919bdaee88ad84614592e171b5ac
parentdcffda935b374e3bcc80d610409569a8450f2891 (diff)
downloadperl-URPM-0df0d67c963e95cff5c834e2bb016161ec241e54.tar
perl-URPM-0df0d67c963e95cff5c834e2bb016161ec241e54.tar.gz
perl-URPM-0df0d67c963e95cff5c834e2bb016161ec241e54.tar.bz2
perl-URPM-0df0d67c963e95cff5c834e2bb016161ec241e54.tar.xz
perl-URPM-0df0d67c963e95cff5c834e2bb016161ec241e54.zip
simplify: newSVpv(foobar, 0) -> newSVpvs(foobar)
-rw-r--r--URPM.xs20
1 files changed, 10 insertions, 10 deletions
diff --git a/URPM.xs b/URPM.xs
index 2e524bf..5fe9175 100644
--- a/URPM.xs
+++ b/URPM.xs
@@ -1078,7 +1078,7 @@ parse_line(AV *depslist, HV *provides, HV *obsoletes, URPM__Package pkg, char *b
pkg->info = memcpy(malloc(data_len), data, data_len);
pkg->flag &= ~FLAG_ID;
pkg->flag |= 1 + av_len(depslist);
- sv_pkg = sv_setref_pv(newSVpv("", 0), "URPM::Package",
+ sv_pkg = sv_setref_pv(newSVpvs(""), "URPM::Package",
_pkg = memcpy(malloc(sizeof(struct s_Package)), pkg, sizeof(struct s_Package)));
if (call_package_callback(urpm, sv_pkg, callback)) {
if (provides) update_provides(_pkg, provides);
@@ -2116,7 +2116,7 @@ Pkg_queryformat(pkg, fmt)
if (pkg->h) {
s = headerFormat(pkg->h, fmt, NULL);
if (s)
- mXPUSHs(newSVpv_utf8(s,0));
+ mXPUSHs(newSVpv_utf8(s, 0));
}
void
@@ -2501,7 +2501,7 @@ Db_traverse(db,callback)
pkg->h = header;
PUSHMARK(SP);
- mXPUSHs(sv_setref_pv(newSVpv("", 0), "URPM::Package", pkg));
+ mXPUSHs(sv_setref_pv(newSVpvs(""), "URPM::Package", pkg));
PUTBACK;
call_sv(callback, G_DISCARD | G_SCALAR);
@@ -2554,7 +2554,7 @@ Db_traverse_tag(db,tag,names,callback)
pkg->h = header;
PUSHMARK(SP);
- mXPUSHs(sv_setref_pv(newSVpv("", 0), "URPM::Package", pkg));
+ mXPUSHs(sv_setref_pv(newSVpvs(""), "URPM::Package", pkg));
PUTBACK;
call_sv(callback, G_DISCARD | G_SCALAR);
@@ -2597,7 +2597,7 @@ Db_traverse_tag_find(db,tag,name,callback)
pkg->h = header;
PUSHMARK(SP);
- mXPUSHs(sv_setref_pv(newSVpv("", 0), "URPM::Package", pkg));
+ mXPUSHs(sv_setref_pv(newSVpvs(""), "URPM::Package", pkg));
PUTBACK;
int count = call_sv(callback, G_SCALAR);
@@ -2735,7 +2735,7 @@ Trans_traverse(trans, callback)
pkg->flag = FLAG_ID_INVALID | FLAG_NO_HEADER_FREE;
pkg->h = h;
PUSHMARK(SP);
- mXPUSHs(sv_setref_pv(newSVpv("", 0), "URPM::Package", pkg));
+ mXPUSHs(sv_setref_pv(newSVpvs(""), "URPM::Package", pkg));
PUTBACK;
call_sv(callback, G_DISCARD | G_SCALAR);
SPAGAIN;
@@ -2767,7 +2767,7 @@ Trans_check(trans, ...)
if (gimme == G_SCALAR)
mXPUSHs(newSViv(0));
else if (gimme == G_ARRAY)
- mXPUSHs(newSVpv("error while checking dependencies", 0));
+ mXPUSHs(newSVpvs("error while checking dependencies"));
} else {
rpmps ps = rpmtsProblems(trans->ts);
if (rpmpsNumProblems(ps) > 0) {
@@ -2798,7 +2798,7 @@ Trans_order(trans)
if (gimme == G_SCALAR)
mXPUSHs(newSViv(0));
else if (gimme == G_ARRAY)
- mXPUSHs(newSVpv("error while ordering dependencies", 0));
+ mXPUSHs(newSVpvs("error while ordering dependencies"));
}
int
@@ -3112,7 +3112,7 @@ Urpm_parse_hdlist__XS(urpm, filename, ...)
memset(&pkg, 0, sizeof(struct s_Package));
pkg.flag = 1 + av_len(depslist);
pkg.h = header;
- sv_pkg = sv_setref_pv(newSVpv("", 0), "URPM::Package",
+ sv_pkg = sv_setref_pv(newSVpvs(""), "URPM::Package",
_pkg = memcpy(malloc(sizeof(struct s_Package)), &pkg, sizeof(struct s_Package)));
if (call_package_callback(urpm, sv_pkg, callback)) {
if (provides) {
@@ -3203,7 +3203,7 @@ Urpm_parse_rpm(urpm, filename, ...)
_pkg = memcpy(malloc(sizeof(struct s_Package)), &pkg, sizeof(struct s_Package));
if (update_header(filename, _pkg, keep_all_tags, vsflags)) {
- sv_pkg = sv_setref_pv(newSVpv("", 0), "URPM::Package", _pkg);
+ sv_pkg = sv_setref_pv(newSVpvs(""), "URPM::Package", _pkg);
if (call_package_callback(urpm, sv_pkg, callback)) {
if (provides) {
update_provides(_pkg, provides);