summaryrefslogtreecommitdiff
path: root/taint.c
diff options
context:
space:
mode:
authorDavid Mitchell <davem@iabyn.com>2013-12-01 11:16:52 +0000
committerDavid Mitchell <davem@iabyn.com>2013-12-01 11:16:52 +0000
commit6fd0695329cb6bc38ec08ec9687424589587902b (patch)
tree2b1ecb492c07193052513f220d9c2efd48c3bf5f /taint.c
parentc6865d2cad76caa20c247a9893c35afa8ba29124 (diff)
downloadperl-6fd0695329cb6bc38ec08ec9687424589587902b.tar.gz
don't check format args on taint_proper
My recent commit 5d37acd6b65eb enabled (among other things) format-arg checking of taint_proper(). This was not a good idea since taint_proper() adds extra args before it actually calls a printf-style function. This was masked since on some gcc systems, a NULLOK format arg disables this check.
Diffstat (limited to 'taint.c')
-rw-r--r--taint.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/taint.c b/taint.c
index 63f0dfccd3..3fc62507ca 100644
--- a/taint.c
+++ b/taint.c
@@ -55,7 +55,10 @@ Perl_taint_proper(pTHX_ const char *f, const char *const s)
else
ug = " while running with -T switch";
- GCC_DIAG_IGNORE(-Wformat-nonliteral); /* fmt checked by caller */
+ /* XXX because taint_proper adds extra format args, we can't
+ * get the caller to check properly; o we just silence the warning
+ * and hope the callers aren't naughty */
+ GCC_DIAG_IGNORE(-Wformat-nonliteral);
if (PL_unsafe || TAINT_WARN_get) {
Perl_ck_warner_d(aTHX_ packWARN(WARN_TAINT), f, s, ug);
}