diff options
author | Gilles Chehade <gilles@cvs.openbsd.org> | 2009-10-18 21:45:48 +0000 |
---|---|---|
committer | Gilles Chehade <gilles@cvs.openbsd.org> | 2009-10-18 21:45:48 +0000 |
commit | 85dd4e6459ee1b701693106667f4a9869ded6571 (patch) | |
tree | e3eb51e1c0f05fb8fa379a9ee95dc49f204f4d24 /usr.sbin/smtpd/lka.c | |
parent | a576084906b44780634136bc1ba6d5c58e5e4a31 (diff) |
actually, we want to resolve C_ALL and C_NET, we just don't want to do it
when their action is to be relayed.
Diffstat (limited to 'usr.sbin/smtpd/lka.c')
-rw-r--r-- | usr.sbin/smtpd/lka.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/usr.sbin/smtpd/lka.c b/usr.sbin/smtpd/lka.c index 0148b6086ff..edbcb5869c2 100644 --- a/usr.sbin/smtpd/lka.c +++ b/usr.sbin/smtpd/lka.c @@ -1,4 +1,4 @@ -/* $OpenBSD: lka.c,v 1.69 2009/10/18 19:53:49 gilles Exp $ */ +/* $OpenBSD: lka.c,v 1.70 2009/10/18 21:45:47 gilles Exp $ */ /* * Copyright (c) 2008 Pierre-Yves Ritschard <pyr@openbsd.org> @@ -996,10 +996,16 @@ lka_expand_rcpt_iteration(struct smtpd *env, struct aliaseslist *aliases, struct int lka_resolve_path(struct smtpd *env, struct path *path){ switch (path->cond->c_type) { + case C_ALL: + case C_NET: case C_DOM: { char username[MAXLOGNAME]; struct passwd *pw; + /* recipient is to be relayed, no need for more processing */ + if (IS_RELAY(*path)) + return 1; + lowercase(username, path->user, sizeof(username)); if (aliases_exist(env, username)) { path->flags |= F_PATH_ALIAS; @@ -1027,9 +1033,6 @@ lka_resolve_path(struct smtpd *env, struct path *path){ } break; } - case C_ALL: - case C_NET: - return 1; default: fatalx("lka_resolve_path: unexpected type"); } |