git://git.exim.org
/
exim.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Debugging: fix potential null-derefs in DSN debug_printfs
[exim.git]
/
src
/
src
/
transport.c
diff --git
a/src/src/transport.c
b/src/src/transport.c
index 5d4102ef8781b21279ae7ab5e38784349423967a..47da45fdfedd4d379df115b18d935b74c09a23d9 100644
(file)
--- a/
src/src/transport.c
+++ b/
src/src/transport.c
@@
-2,7
+2,7
@@
* Exim - an Internet mail transport agent *
*************************************************/
* Exim - an Internet mail transport agent *
*************************************************/
-/* Copyright (c) University of Cambridge 1995 - 201
6
*/
+/* Copyright (c) University of Cambridge 1995 - 201
7
*/
/* See the file NOTICE for conditions of use and distribution. */
/* General functions concerned with transportation, and generic options for all
/* See the file NOTICE for conditions of use and distribution. */
/* General functions concerned with transportation, and generic options for all
@@
-346,12
+346,9
@@
if (!(tctx->options & topt_output_string))
/* Write to expanding-string. NOTE: not NUL-terminated */
if (!tctx->u.msg)
/* Write to expanding-string. NOTE: not NUL-terminated */
if (!tctx->u.msg)
- {
- tctx->u.msg = store_get(tctx->msg_size = 1024);
- tctx->msg_ptr = 0;
- }
+ tctx->u.msg = string_get(1024);
-tctx->u.msg = string_catn(tctx->u.msg,
&tctx->msg_size, &tctx->msg_ptr,
block, len);
+tctx->u.msg = string_catn(tctx->u.msg, block, len);
return TRUE;
}
return TRUE;
}
@@
-591,7
+588,7
@@
at = Ustrrchr(addr->address, '@');
plen = (addr->prefix == NULL)? 0 : Ustrlen(addr->prefix);
slen = Ustrlen(addr->suffix);
plen = (addr->prefix == NULL)? 0 : Ustrlen(addr->prefix);
slen = Ustrlen(addr->suffix);
-return string_sprintf("%.*s@%s", (at - addr->address - plen - slen),
+return string_sprintf("%.*s@%s", (
int)(
at - addr->address - plen - slen),
addr->address + plen, at + 1);
}
addr->address + plen, at + 1);
}