From 84450e5e0a0a383fafcccda9da65a3ac5660804c Mon Sep 17 00:00:00 2001 From: eric Date: Fri, 28 Dec 2018 13:47:54 +0000 Subject: [PATCH] simplify code ok gilles@ --- usr.sbin/smtpd/table.c | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/usr.sbin/smtpd/table.c b/usr.sbin/smtpd/table.c index 0526faab2f8..5e646bc0233 100644 --- a/usr.sbin/smtpd/table.c +++ b/usr.sbin/smtpd/table.c @@ -1,4 +1,4 @@ -/* $OpenBSD: table.c,v 1.45 2018/12/28 11:40:29 eric Exp $ */ +/* $OpenBSD: table.c,v 1.46 2018/12/28 13:47:54 eric Exp $ */ /* * Copyright (c) 2013 Eric Faurot @@ -224,13 +224,6 @@ table_create(struct smtpd *conf, const char *backend, const char *name, t = xcalloc(1, sizeof(*t)); t->t_backend = tb; - /* XXX */ - /* - * until people forget about it, "file" really means "static" - */ - if (!strcmp(backend, "file")) - backend = "static"; - if (config) { if (strlcpy(t->t_config, config, sizeof t->t_config) >= sizeof t->t_config) @@ -238,7 +231,7 @@ table_create(struct smtpd *conf, const char *backend, const char *name, t->t_config); } - if (strcmp(backend, "static") != 0) + if (strcmp(tb->name, "static") != 0) t->t_type = T_DYNAMIC; if (name == NULL) -- 2.20.1