aboutsummaryrefslogtreecommitdiff
path: root/mailutils/sendmail.c
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2017-08-05 17:50:35 +0200
committerDenys Vlasenko <vda.linux@googlemail.com>2017-08-05 17:50:35 +0200
commit20077c1429915b2c223e4d179a033f2b1806872c (patch)
tree76c89e23adc5bb529e310d9e25e7016f6d699645 /mailutils/sendmail.c
parent9cf89cdf84fb20154088145980b676d2b28fc55d (diff)
downloadbusybox-w32-20077c1429915b2c223e4d179a033f2b1806872c.tar.gz
busybox-w32-20077c1429915b2c223e4d179a033f2b1806872c.tar.bz2
busybox-w32-20077c1429915b2c223e4d179a033f2b1806872c.zip
libbb: make trim() return pointer to terminating NUL
function old new delta trim 80 90 +10 angle_address 56 50 -6 sysctl_main 282 273 -9 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 1/3 up/down: +10/-15) Total: -5 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'mailutils/sendmail.c')
-rw-r--r--mailutils/sendmail.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/mailutils/sendmail.c b/mailutils/sendmail.c
index 346de2712..65895f0ec 100644
--- a/mailutils/sendmail.c
+++ b/mailutils/sendmail.c
@@ -166,9 +166,8 @@ static char *angle_address(char *str)
166{ 166{
167 char *s, *e; 167 char *s, *e;
168 168
169 trim(str); 169 e = trim(str);
170 e = last_char_is(str, '>'); 170 if (e != str && e[-1] == '>') {
171 if (e) {
172 s = strrchr(str, '<'); 171 s = strrchr(str, '<');
173 if (s) { 172 if (s) {
174 *e = '\0'; 173 *e = '\0';