summaryrefslogtreecommitdiff
path: root/src/libwpactrl/wpactrl_ackmsg.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/libwpactrl/wpactrl_ackmsg.c')
-rw-r--r--src/libwpactrl/wpactrl_ackmsg.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/libwpactrl/wpactrl_ackmsg.c b/src/libwpactrl/wpactrl_ackmsg.c
new file mode 100644
index 0000000..6d0d3b6
--- /dev/null
+++ b/src/libwpactrl/wpactrl_ackmsg.c
@@ -0,0 +1,14 @@
+/* ISC license. */
+
+#include <string.h>
+#include <bcnm/wpactrl.h>
+
+void wpactrl_ackmsg (wpactrl_t *a)
+{
+ if (a->datahead < a->data.len) a->datahead += strlen(a->data.s + a->datahead) + 1 ;
+ if (a->datahead >= a->data.len)
+ {
+ a->data.len = 0 ;
+ a->datahead = 0 ;
+ }
+}