From 89cf363061d74e835da24f2abec26683064b56fd Mon Sep 17 00:00:00 2001 From: Eric Blake Date: Wed, 28 Nov 2012 09:20:49 -0700 Subject: [PATCH] nwfilter: drop dead code Commit cb022152 went overboard and introduced a dead conditional while trying to get rid of a potential NULL dereference. * src/nwfilter/nwfilter_dhcpsnoop.c (virNWFilterSnoopReqNew): Remove redundant conditional. --- src/nwfilter/nwfilter_dhcpsnoop.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/nwfilter/nwfilter_dhcpsnoop.c b/src/nwfilter/nwfilter_dhcpsnoop.c index 3321d0bf23..e4c895fc4d 100644 --- a/src/nwfilter/nwfilter_dhcpsnoop.c +++ b/src/nwfilter/nwfilter_dhcpsnoop.c @@ -573,7 +573,7 @@ virNWFilterSnoopReqNew(const char *ifkey) { virNWFilterSnoopReqPtr req; - if (ifkey == NULL || (ifkey && (strlen(ifkey) != VIR_IFKEY_LEN - 1))) { + if (ifkey == NULL || strlen(ifkey) != VIR_IFKEY_LEN - 1) { virReportError(VIR_ERR_INTERNAL_ERROR, _("virNWFilterSnoopReqNew called with invalid " "key \"%s\" (%zu)"),