summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLaurent Bercot <ska-skaware@skarnet.org>2019-11-19 16:33:48 +0000
committerLaurent Bercot <ska-skaware@skarnet.org>2019-11-19 16:33:48 +0000
commit64c5e558ff00b1cb366e6b8500723c254164418a (patch)
tree6205f7e7f27f22b4fcc812271f4d2fb5e5b9c3da /src
parent05e3598a6d58dffddcc3cf3862027533ea605a74 (diff)
downloadbcnm-64c5e558ff00b1cb366e6b8500723c254164418a.tar.xz
bugfix: properly \0-terminate filters
Diffstat (limited to 'src')
-rw-r--r--src/libwpactrl/wpactrl_filter_add.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libwpactrl/wpactrl_filter_add.c b/src/libwpactrl/wpactrl_filter_add.c
index 52e5b3a..c5d8ebc 100644
--- a/src/libwpactrl/wpactrl_filter_add.c
+++ b/src/libwpactrl/wpactrl_filter_add.c
@@ -9,5 +9,5 @@
int wpactrl_filter_add (wpactrl_t *a, char const *s)
{
if (wpactrl_filter_exact_search(a, s) < a->filters.len) return (errno = EBUSY, 0) ;
- return stralloc_catb(&a->filters, s, strlen(s)) ;
+ return stralloc_catb(&a->filters, s, strlen(s) + 1) ;
}