From: Phil Sutter <phil@nwl.cc>
To: Pablo Neira Ayuso <pablo@netfilter.org>
Cc: netfilter-devel@vger.kernel.org
Subject: [conntrack-tools PATCH 7/8] Drop pointless assignments
Date: Fri, 25 Mar 2022 11:50:02 +0100 [thread overview]
Message-ID: <20220325105003.26621-8-phil@nwl.cc> (raw)
In-Reply-To: <20220325105003.26621-1-phil@nwl.cc>
These variables are not referred to after assigning within their scope
(or until they're overwritten).
Signed-off-by: Phil Sutter <phil@nwl.cc>
---
src/helpers/ssdp.c | 1 -
src/main.c | 2 +-
2 files changed, 1 insertion(+), 2 deletions(-)
diff --git a/src/helpers/ssdp.c b/src/helpers/ssdp.c
index 0c6f563c592aa..527892cdabf8a 100644
--- a/src/helpers/ssdp.c
+++ b/src/helpers/ssdp.c
@@ -256,7 +256,6 @@ static int find_hdr(const char *name, const uint8_t *data, int data_len,
data += i+2;
}
- data_len -= name_len;
data += name_len;
if (pos)
*pos = data;
diff --git a/src/main.c b/src/main.c
index 31e0eed950b48..de4773df8a204 100644
--- a/src/main.c
+++ b/src/main.c
@@ -319,7 +319,7 @@ int main(int argc, char *argv[])
umask(0177);
- if ((ret = init_config(config_file)) == -1) {
+ if (init_config(config_file) == -1) {
dlog(LOG_ERR, "can't open config file `%s'", config_file);
exit(EXIT_FAILURE);
}
--
2.34.1
next prev parent reply other threads:[~2022-03-25 10:50 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-03-25 10:49 [conntrack-tools PATCH 0/8] Fixes for a recent Coverity tool run Phil Sutter
2022-03-25 10:49 ` [conntrack-tools PATCH 1/8] hash: Flush tables when destroying Phil Sutter
2022-03-25 10:49 ` [conntrack-tools PATCH 2/8] cache: Fix features array allocation Phil Sutter
2022-03-25 10:49 ` [conntrack-tools PATCH 3/8] Fix potential buffer overrun in snprintf() calls Phil Sutter
2022-03-25 10:49 ` [conntrack-tools PATCH 4/8] helpers: ftp: Avoid ugly casts Phil Sutter
2022-03-25 10:50 ` [conntrack-tools PATCH 5/8] read_config_yy: Drop extra argument from dlog() call Phil Sutter
2022-03-25 10:50 ` [conntrack-tools PATCH 6/8] Don't call exit() from signal handler Phil Sutter
2022-03-25 10:50 ` Phil Sutter [this message]
2022-03-25 10:50 ` [conntrack-tools PATCH 8/8] connntrack: Fix for memleak when parsing -j arg Phil Sutter
2022-03-28 8:25 ` [conntrack-tools PATCH 0/8] Fixes for a recent Coverity tool run Pablo Neira Ayuso
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220325105003.26621-8-phil@nwl.cc \
--to=phil@nwl.cc \
--cc=netfilter-devel@vger.kernel.org \
--cc=pablo@netfilter.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.