From f16a15c39c872c5f42eb554deb4d956264c0c823 Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Tue, 24 Sep 2013 10:47:47 +0200 Subject: proto-shell: move script handler dump code to handler.c Signed-off-by: Felix Fietkau --- handler.h | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 handler.h (limited to 'handler.h') diff --git a/handler.h b/handler.h new file mode 100644 index 0000000..02438f2 --- /dev/null +++ b/handler.h @@ -0,0 +1,24 @@ +/* + * netifd - network interface daemon + * Copyright (C) 2012-2013 Felix Fietkau + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 + * as published by the Free Software Foundation + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + */ +#ifndef __NETIFD_HANDLER_H +#define __NETIFD_HANDLER_H + +#include + +typedef void (*script_dump_cb)(const char *name, json_object *obj); + +int netifd_open_subdir(const char *name); +void netifd_init_script_handlers(int dir_fd, script_dump_cb cb); + +#endif -- cgit v1.2.1