summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorgilles <gilles@openbsd.org>2016-05-21 19:28:19 +0000
committergilles <gilles@openbsd.org>2016-05-21 19:28:19 +0000
commit1c66dff135e2ad6f6c8e27930e2b0ab108f85f9c (patch)
tree6a50c4a132859aeb0f680a926c6b0bdc122fbb31
parentno more -x; (diff)
downloadwireguard-openbsd-1c66dff135e2ad6f6c8e27930e2b0ab108f85f9c.tar.xz
wireguard-openbsd-1c66dff135e2ad6f6c8e27930e2b0ab108f85f9c.zip
replace hardcoded '+' with TAG_CHAR define
diff from obadz <github@obadz.com>
-rw-r--r--usr.sbin/smtpd/aliases.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/usr.sbin/smtpd/aliases.c b/usr.sbin/smtpd/aliases.c
index 29d2b0e5e6c..20645878ba5 100644
--- a/usr.sbin/smtpd/aliases.c
+++ b/usr.sbin/smtpd/aliases.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: aliases.c,v 1.69 2015/12/28 22:08:30 jung Exp $ */
+/* $OpenBSD: aliases.c,v 1.70 2016/05/21 19:28:19 gilles Exp $ */
/*
* Copyright (c) 2008 Gilles Chehade <gilles@poolp.org>
@@ -126,8 +126,8 @@ aliases_virtual_get(struct expand *expand, const struct mailaddr *maddr)
/* first, check if entry has a user-part tag */
if (tag[0]) {
- if (!bsnprintf(buf, sizeof(buf), "%s+%s@%s",
- user, tag, domain))
+ if (!bsnprintf(buf, sizeof(buf), "%s%c%s@%s",
+ user, TAG_CHAR, tag, domain))
return 0;
ret = table_lookup(mapping, NULL, buf, K_ALIAS, &lk);
if (ret < 0)
@@ -147,7 +147,7 @@ aliases_virtual_get(struct expand *expand, const struct mailaddr *maddr)
if (tag[0]) {
/* Failed ? We lookup for username + user-part tag */
- if (!bsnprintf(buf, sizeof(buf), "%s+%s", user, tag))
+ if (!bsnprintf(buf, sizeof(buf), "%s%c%s", user, TAG_CHAR, tag))
return 0;
ret = table_lookup(mapping, NULL, buf, K_ALIAS, &lk);
if (ret < 0)