From 1f9f9b9a395351fd2b001c24ffe89c546723763d Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?P=C5=99emysl=20Janouch?=
Date: Tue, 23 Sep 2014 22:59:01 +0200
Subject: Simplify the plugin API
---
plugin-api.h | 11 ++++-------
1 file changed, 4 insertions(+), 7 deletions(-)
(limited to 'plugin-api.h')
diff --git a/plugin-api.h b/plugin-api.h
index fa67695..f74b069 100644
--- a/plugin-api.h
+++ b/plugin-api.h
@@ -47,22 +47,19 @@ struct service
/// Destroy the handle created for the scan
void (*scan_free) (void *handle);
- // XXX: maybe force the service to store a reference to the unit?
-
/// We have received some data from the peer
- // FIXME: the dependency on `struct str' is not very good
- void (*on_data) (void *handle, struct unit *u, struct str *data);
+ void (*on_data) (void *handle, const void *data, size_t len);
/// Server has closed the connection
- void (*on_eof) (void *handle, struct unit *u);
+ void (*on_eof) (void *handle);
// XXX: do we need these at all? Is there any use for them?
/// Network or other error has occured
- void (*on_error) (void *handle, struct unit *u);
+ void (*on_error) (void *handle);
/// The scan has been aborted
- void (*on_aborted) (void *handle, struct unit *u);
+ void (*on_aborted) (void *handle);
};
struct plugin_api
--
cgit v1.2.3