git://git.exim.org
/
exim.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
8021b95
)
Silence compiler
author
Heiko Schlittermann (HS12-RIPE)
<hs@schlittermann.de>
Fri, 23 Apr 2021 15:40:40 +0000
(17:40 +0200)
committer
Heiko Schlittermann (HS12-RIPE)
<hs@schlittermann.de>
Fri, 23 Apr 2021 20:55:40 +0000
(22:55 +0200)
src/src/acl.c
patch
|
blob
|
history
src/src/deliver.c
patch
|
blob
|
history
src/src/expand.c
patch
|
blob
|
history
src/src/functions.h
patch
|
blob
|
history
src/src/lookups/lf_sqlperform.c
patch
|
blob
|
history
src/src/parse.c
patch
|
blob
|
history
src/src/rda.c
patch
|
blob
|
history
src/src/transports/appendfile.c
patch
|
blob
|
history
src/src/transports/autoreply.c
patch
|
blob
|
history
src/src/transports/pipe.c
patch
|
blob
|
history
diff --git
a/src/src/acl.c
b/src/src/acl.c
index 81beab5f37773a7c0101e4fc284a87dc80de5de1..b62af5c6555275119f77bc1082a8a8c20f5a9fd7 100644
(file)
--- a/
src/src/acl.c
+++ b/
src/src/acl.c
@@
-3600,7
+3600,7
@@
for (; cb; cb = cb->next)
case ACLC_QUEUE:
{
uschar *m;
case ACLC_QUEUE:
{
uschar *m;
- if (
m = is_tainted2(arg, 0, "Tainted name '%s' for queue not permitted", arg
))
+ if (
(m = is_tainted2(arg, 0, "Tainted name '%s' for queue not permitted", arg)
))
{
*log_msgptr = m;
return ERROR;
{
*log_msgptr = m;
return ERROR;
diff --git
a/src/src/deliver.c
b/src/src/deliver.c
index 87e944b03799d0b92cf36e7880adf89cb1546574..b40eed4f91620f34943f83f5af4302b11bc18407 100644
(file)
--- a/
src/src/deliver.c
+++ b/
src/src/deliver.c
@@
-6149,12
+6149,11
@@
else if (system_filter && process_recipients != RECIP_FAIL_TIMEOUT)
{
uschar *tmp = expand_string(tpname);
address_file = address_pipe = NULL;
{
uschar *tmp = expand_string(tpname);
address_file = address_pipe = NULL;
- uschar *m;
if (!tmp)
p->message = string_sprintf("failed to expand \"%s\" as a "
"system filter transport name", tpname);
{ uschar *m;
if (!tmp)
p->message = string_sprintf("failed to expand \"%s\" as a "
"system filter transport name", tpname);
{ uschar *m;
- if (
m = is_tainted2(tmp, 0, "Tainted values '%s' " "for transport '%s' as a system filter", tmp, tpname
))
+ if (
(m = is_tainted2(tmp, 0, "Tainted values '%s' " "for transport '%s' as a system filter", tmp, tpname)
))
p->message = m;
}
tpname = tmp;
p->message = m;
}
tpname = tmp;
diff --git
a/src/src/expand.c
b/src/src/expand.c
index 21b86ebf5781c4e2b6ed7a066e5ca4fbf0b0ad21..dc4b4e1020d925a42afe0fe4bd68704a14a130e6 100644
(file)
--- a/
src/src/expand.c
+++ b/
src/src/expand.c
@@
-4384,7
+4384,7
@@
f.expand_string_forcedfail = FALSE;
expand_string_message = US"";
{ uschar *m;
expand_string_message = US"";
{ uschar *m;
-if (
m = is_tainted2(string, LOG_MAIN|LOG_PANIC, "Tainted string '%s' in expansion", s
))
+if (
(m = is_tainted2(string, LOG_MAIN|LOG_PANIC, "Tainted string '%s' in expansion", s)
))
{
expand_string_message = m;
goto EXPAND_FAILED;
{
expand_string_message = m;
goto EXPAND_FAILED;
@@
-7629,10
+7629,12
@@
while (*s != 0)
/* Manually track tainting, as we deal in individual chars below */
if (is_tainted(sub))
/* Manually track tainting, as we deal in individual chars below */
if (is_tainted(sub))
+ {
if (yield->s && yield->ptr)
gstring_rebuffer(yield);
else
yield->s = store_get(yield->size = Ustrlen(sub), TRUE);
if (yield->s && yield->ptr)
gstring_rebuffer(yield);
else
yield->s = store_get(yield->size = Ustrlen(sub), TRUE);
+ }
/* Check the UTF-8, byte-by-byte */
/* Check the UTF-8, byte-by-byte */
@@
-8193,6
+8195,7
@@
that is a bad idea, because expand_string_message is in dynamic store. */
EXPAND_FAILED:
if (left) *left = s;
DEBUG(D_expand)
EXPAND_FAILED:
if (left) *left = s;
DEBUG(D_expand)
+ {
DEBUG(D_noutf8)
{
debug_printf_indent("|failed to expand: %s\n", string);
DEBUG(D_noutf8)
{
debug_printf_indent("|failed to expand: %s\n", string);
@@
-8212,6
+8215,7
@@
DEBUG(D_expand)
if (f.expand_string_forcedfail)
debug_printf_indent(UTF8_UP_RIGHT "failure was forced\n");
}
if (f.expand_string_forcedfail)
debug_printf_indent(UTF8_UP_RIGHT "failure was forced\n");
}
+ }
if (resetok_p && !resetok) *resetok_p = FALSE;
expand_level--;
return NULL;
if (resetok_p && !resetok) *resetok_p = FALSE;
expand_level--;
return NULL;
diff --git
a/src/src/functions.h
b/src/src/functions.h
index 1e8083673803621d37fff303c4873d28b5466dd2..b4d23c4bc4c4baf781ec3650f00ea08af86bea82 100644
(file)
--- a/
src/src/functions.h
+++ b/
src/src/functions.h
@@
-1084,7
+1084,7
@@
if (f.running_in_test_harness && f.testsuite_delays) millisleep(millisec);
/******************************************************************************/
/* Taint-checked file opens */
static inline uschar *
/******************************************************************************/
/* Taint-checked file opens */
static inline uschar *
-is_tainted2(const void *p, int lflags, const
us
char* fmt, ...)
+is_tainted2(const void *p, int lflags, const char* fmt, ...)
{
va_list ap;
uschar *msg;
{
va_list ap;
uschar *msg;
diff --git
a/src/src/lookups/lf_sqlperform.c
b/src/src/lookups/lf_sqlperform.c
index eda3089e256e89ec56e9fd0b267fe3539590f0a0..38b7c2ad345c4bde4f6cbcadb74ae42994eb2f8a 100644
(file)
--- a/
src/src/lookups/lf_sqlperform.c
+++ b/
src/src/lookups/lf_sqlperform.c
@@
-103,7
+103,7
@@
if (Ustrncmp(query, "servers", 7) == 0)
}
{ uschar *m;
}
{ uschar *m;
- if (
m = is_tainted2(server, 0, "Tainted %s server '%s'", name, server
))
+ if (
(m = is_tainted2(server, 0, "Tainted %s server '%s'", name, server)
))
{
*errmsg = m;
return DEFER;
{
*errmsg = m;
return DEFER;
@@
-161,7
+161,7
@@
else
}
{ uschar *m;
}
{ uschar *m;
- if (
is_tainted2(server, 0, "Tainted %s server '%s'", name, server
))
+ if (
(m = is_tainted2(server, 0, "Tainted %s server '%s'", name, server)
))
{
*errmsg = m;
return DEFER;
{
*errmsg = m;
return DEFER;
diff --git
a/src/src/parse.c
b/src/src/parse.c
index d1bc79039cc129c9302103c9fbf6995a6e4a836d..0622b3127354c41b7d0b7705a97d0a0a947f56a9 100644
(file)
--- a/
src/src/parse.c
+++ b/
src/src/parse.c
@@
-1402,7
+1402,7
@@
for (;;)
return FF_ERROR;
}
return FF_ERROR;
}
- if (
*error = is_tainted2(filename, 0, "Tainted name '%s' for included file not permitted\n", filename
))
+ if (
(*error = is_tainted2(filename, 0, "Tainted name '%s' for included file not permitted\n", filename)
))
return FF_ERROR;
/* Check file name if required */
return FF_ERROR;
/* Check file name if required */
diff --git
a/src/src/rda.c
b/src/src/rda.c
index 6ad7dd8bdb3b3136b76fce1d6097719985edeb1b..bba0b719b6f4c10318993a1ffb234ee73e9cdba1 100644
(file)
--- a/
src/src/rda.c
+++ b/
src/src/rda.c
@@
-179,7
+179,7
@@
struct stat statbuf;
/* Reading a file is a form of expansion; we wish to deny attackers the
capability to specify the file name. */
/* Reading a file is a form of expansion; we wish to deny attackers the
capability to specify the file name. */
-if (
*error = is_tainted2(filename, 0, "Tainted name '%s' for file read not permitted\n", filename
))
+if (
(*error = is_tainted2(filename, 0, "Tainted name '%s' for file read not permitted\n", filename)
))
{
*yield = FF_ERROR;
return NULL;
{
*yield = FF_ERROR;
return NULL;
diff --git
a/src/src/transports/appendfile.c
b/src/src/transports/appendfile.c
index 7dbbaa2f9b223bb23b070b3dbe4d8cd86c05a474..6772b338bbf30a9dd6b3aeb37f45fb4bd87d53e2 100644
(file)
--- a/
src/src/transports/appendfile.c
+++ b/
src/src/transports/appendfile.c
@@
-1287,8
+1287,8
@@
if (!(path = expand_string(fdname)))
goto ret_panic;
}
{ uschar *m;
goto ret_panic;
}
{ uschar *m;
-if (m = is_tainted2(path, 0, "Tainted '%s' (file or directory "
- "name for %s transport) not permitted", path, tblock->name))
+if (
(
m = is_tainted2(path, 0, "Tainted '%s' (file or directory "
+ "name for %s transport) not permitted", path, tblock->name))
)
{
addr->message = m;
goto ret_panic;
{
addr->message = m;
goto ret_panic;
diff --git
a/src/src/transports/autoreply.c
b/src/src/transports/autoreply.c
index ed99de4c6ec19bc6c49ea4a946fa48475c55c350..80c7c0db0c655306709facc766c9070b5dabadcf 100644
(file)
--- a/
src/src/transports/autoreply.c
+++ b/
src/src/transports/autoreply.c
@@
-407,8
+407,8
@@
if (oncelog && *oncelog && to)
uschar *m;
time_t then = 0;
uschar *m;
time_t then = 0;
- if (m = is_tainted2(oncelog, 0, "Tainted '%s' (once file for %s transport)"
- " not permitted", oncelog, tblock->name))
+ if (
(
m = is_tainted2(oncelog, 0, "Tainted '%s' (once file for %s transport)"
+ " not permitted", oncelog, tblock->name))
)
{
addr->transport_return = DEFER;
addr->basic_errno = EACCES;
{
addr->transport_return = DEFER;
addr->basic_errno = EACCES;
@@
-518,8
+518,8
@@
if (oncelog && *oncelog && to)
{
uschar *m;
int log_fd;
{
uschar *m;
int log_fd;
- if (m = is_tainted2(logfile, 0, "Tainted '%s' (logfile for %s transport)"
- " not permitted", logfile, tblock->name))
+ if (
(
m = is_tainted2(logfile, 0, "Tainted '%s' (logfile for %s transport)"
+ " not permitted", logfile, tblock->name))
)
{
addr->transport_return = DEFER;
addr->basic_errno = EACCES;
{
addr->transport_return = DEFER;
addr->basic_errno = EACCES;
@@
-551,8
+551,8
@@
if (oncelog && *oncelog && to)
if (file)
{
uschar *m;
if (file)
{
uschar *m;
- if (m = is_tainted2(file, 0, "Tainted '%s' (file for %s transport)"
- " not permitted", file, tblock->name))
+ if (
(
m = is_tainted2(file, 0, "Tainted '%s' (file for %s transport)"
+ " not permitted", file, tblock->name))
)
{
addr->transport_return = DEFER;
addr->basic_errno = EACCES;
{
addr->transport_return = DEFER;
addr->basic_errno = EACCES;
diff --git
a/src/src/transports/pipe.c
b/src/src/transports/pipe.c
index 4c9e68beb263d93fbfc48871f60d3b29ac39b2cf..fc44fa585852b1e2ce405181d2443817ae450cf7 100644
(file)
--- a/
src/src/transports/pipe.c
+++ b/
src/src/transports/pipe.c
@@
-601,8
+601,8
@@
if (!cmd || !*cmd)
}
{ uschar *m;
}
{ uschar *m;
-if (m = is_tainted2(cmd, 0, "Tainted '%s' (command "
- "for %s transport) not permitted", cmd, tblock->name))
+if (
(
m = is_tainted2(cmd, 0, "Tainted '%s' (command "
+ "for %s transport) not permitted", cmd, tblock->name))
)
{
addr->transport_return = PANIC;
addr->message = m;
{
addr->transport_return = PANIC;
addr->message = m;