diff options
author | Alexander Wirt <formorer@debian.org> | 2013-05-18 21:48:14 +0200 |
---|---|---|
committer | Alexander Wirt <formorer@debian.org> | 2013-05-18 21:48:14 +0200 |
commit | 6b61aefbf3de71852386f5f26d60c10ef62407d3 (patch) | |
tree | 3f3bc8e11f487c990c57e8a345db2040b3e9a66c /src/filter.c | |
parent | ea27bb406e3d8fe9466ba274af38e6f540ff5bfc (diff) | |
download | conntrack-tools-6b61aefbf3de71852386f5f26d60c10ef62407d3.tar.gz conntrack-tools-6b61aefbf3de71852386f5f26d60c10ef62407d3.zip |
Imported Upstream version 1.4.1
Diffstat (limited to 'src/filter.c')
-rw-r--r-- | src/filter.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/src/filter.c b/src/filter.c index 39dd4ca..02a8078 100644 --- a/src/filter.c +++ b/src/filter.c @@ -473,7 +473,17 @@ int exp_filter_find(struct exp_filter *f, const struct nf_expect *exp) return 1; list_for_each_entry(item, &f->list, head) { - const char *name = nfexp_get_attr(exp, ATTR_EXP_HELPER_NAME); + const char *name; + + if (nfexp_attr_is_set(exp, ATTR_EXP_HELPER_NAME)) + name = nfexp_get_attr(exp, ATTR_EXP_HELPER_NAME); + else { + /* No helper name, this is likely to be a kernel older + * which does not include the helper name, just skip + * this so we don't crash. + */ + return 0; + } /* we allow partial matching to support things like sip-PORT. */ if (strncasecmp(item->helper_name, name, |