Cleanup
This commit is contained in:
parent
89864c330c
commit
e980a38b4e
@ -24,8 +24,8 @@
|
|||||||
# define NDPPD_ALLOC_SIZE 16384
|
# define NDPPD_ALLOC_SIZE 16384
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include "ndppd.h"
|
|
||||||
#include "alloc.h"
|
#include "alloc.h"
|
||||||
|
#include "ndppd.h"
|
||||||
|
|
||||||
typedef struct ndL_chunk ndL_chunk_t;
|
typedef struct ndL_chunk ndL_chunk_t;
|
||||||
|
|
||||||
|
@ -16,12 +16,11 @@
|
|||||||
* You should have received a copy of the GNU General Public License
|
* You should have received a copy of the GNU General Public License
|
||||||
* along with ndppd. If not, see <https://www.gnu.org/licenses/>.
|
* along with ndppd. If not, see <https://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
#ifndef NDPPD_CF_H
|
#ifndef NDPPD_CONF_H
|
||||||
#define NDPPD_CF_H
|
#define NDPPD_CONF_H
|
||||||
|
|
||||||
#include "ndppd.h"
|
#include "ndppd.h"
|
||||||
|
|
||||||
/* cf.c */
|
|
||||||
bool nd_conf_load(const char *path);
|
bool nd_conf_load(const char *path);
|
||||||
|
|
||||||
#endif // NDPPD_CF_H
|
#endif /* NDPPD_CONF_H */
|
||||||
|
@ -16,8 +16,8 @@
|
|||||||
* You should have received a copy of the GNU General Public License
|
* You should have received a copy of the GNU General Public License
|
||||||
* along with ndppd. If not, see <https://www.gnu.org/licenses/>.
|
* along with ndppd. If not, see <https://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
#ifndef NDPPD_IFA_H
|
#ifndef NDPPD_IFACE_H
|
||||||
#define NDPPD_IFA_H
|
#define NDPPD_IFACE_H
|
||||||
|
|
||||||
#include "ndppd.h"
|
#include "ndppd.h"
|
||||||
#include <net/if.h>
|
#include <net/if.h>
|
||||||
@ -51,4 +51,4 @@ bool nd_iface_set_allmulti(nd_iface_t *iface, bool on);
|
|||||||
bool nd_iface_set_promisc(nd_iface_t *iface, bool on);
|
bool nd_iface_set_promisc(nd_iface_t *iface, bool on);
|
||||||
void nd_iface_cleanup();
|
void nd_iface_cleanup();
|
||||||
|
|
||||||
#endif /* NDPPD_IFA_H */
|
#endif /* NDPPD_IFACE_H */
|
||||||
|
@ -119,7 +119,6 @@ static bool ndL_daemonize()
|
|||||||
close(STDOUT_FILENO);
|
close(STDOUT_FILENO);
|
||||||
close(STDERR_FILENO);
|
close(STDERR_FILENO);
|
||||||
|
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -35,10 +35,9 @@ struct nd_proxy
|
|||||||
bool promisc;
|
bool promisc;
|
||||||
};
|
};
|
||||||
|
|
||||||
/* proxy.c */
|
|
||||||
nd_proxy_t *nd_proxy_create(const char *ifname);
|
nd_proxy_t *nd_proxy_create(const char *ifname);
|
||||||
void nd_proxy_handle_ns(nd_proxy_t *proxy, nd_addr_t *src, nd_addr_t *dst, nd_addr_t *tgt, uint8_t *src_ll);
|
void nd_proxy_handle_ns(nd_proxy_t *proxy, nd_addr_t *src, nd_addr_t *dst, nd_addr_t *tgt, uint8_t *src_ll);
|
||||||
bool nd_proxy_startup();
|
bool nd_proxy_startup();
|
||||||
void nd_proxy_update_all();
|
void nd_proxy_update_all();
|
||||||
|
|
||||||
#endif // NDPPD_PROXY_H
|
#endif /* NDPPD_PROXY_H */
|
||||||
|
@ -44,7 +44,6 @@ struct nd_rtnl_addr
|
|||||||
|
|
||||||
extern long nd_rtnl_dump_timeout;
|
extern long nd_rtnl_dump_timeout;
|
||||||
|
|
||||||
|
|
||||||
bool nd_rtnl_open();
|
bool nd_rtnl_open();
|
||||||
void nd_rtnl_cleanup();
|
void nd_rtnl_cleanup();
|
||||||
bool nd_rtnl_query_addresses();
|
bool nd_rtnl_query_addresses();
|
||||||
|
@ -16,9 +16,9 @@
|
|||||||
* You should have received a copy of the GNU General Public License
|
* You should have received a copy of the GNU General Public License
|
||||||
* along with ndppd. If not, see <https://www.gnu.org/licenses/>.
|
* along with ndppd. If not, see <https://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
#include "rule.h"
|
||||||
#include "ndppd.h"
|
#include "ndppd.h"
|
||||||
#include "proxy.h"
|
#include "proxy.h"
|
||||||
#include "rule.h"
|
|
||||||
|
|
||||||
nd_rule_t *nd_rule_create(nd_proxy_t *proxy)
|
nd_rule_t *nd_rule_create(nd_proxy_t *proxy)
|
||||||
{
|
{
|
||||||
|
@ -19,6 +19,8 @@
|
|||||||
#ifndef NDPPD_RULE_H
|
#ifndef NDPPD_RULE_H
|
||||||
#define NDPPD_RULE_H
|
#define NDPPD_RULE_H
|
||||||
|
|
||||||
|
#include <net/if.h>
|
||||||
|
|
||||||
#include "ndppd.h"
|
#include "ndppd.h"
|
||||||
|
|
||||||
struct nd_rule
|
struct nd_rule
|
||||||
@ -34,7 +36,6 @@ struct nd_rule
|
|||||||
bool is_auto;
|
bool is_auto;
|
||||||
};
|
};
|
||||||
|
|
||||||
/* rule.c */
|
|
||||||
nd_rule_t *nd_rule_create(nd_proxy_t *proxy);
|
nd_rule_t *nd_rule_create(nd_proxy_t *proxy);
|
||||||
|
|
||||||
#endif // NDPPD_RULE_H
|
#endif /* NDPPD_RULE_H */
|
||||||
|
@ -62,4 +62,4 @@ struct nd_session
|
|||||||
nd_session_t *nd_alloc_session();
|
nd_session_t *nd_alloc_session();
|
||||||
void nd_free_session(nd_session_t *session);
|
void nd_free_session(nd_session_t *session);
|
||||||
|
|
||||||
#endif /*NDPPD_SESSION_H*/
|
#endif /* NDPPD_SESSION_H */
|
||||||
|
@ -31,7 +31,6 @@ struct nd_sio
|
|||||||
nd_sio_handler_t *handler;
|
nd_sio_handler_t *handler;
|
||||||
};
|
};
|
||||||
|
|
||||||
/* sio.c */
|
|
||||||
nd_sio_t *nd_sio_open(int domain, int type, int protocol);
|
nd_sio_t *nd_sio_open(int domain, int type, int protocol);
|
||||||
void nd_sio_close(nd_sio_t *nio);
|
void nd_sio_close(nd_sio_t *nio);
|
||||||
bool nd_sio_bind(nd_sio_t *sio, const struct sockaddr *addr, size_t addrlen);
|
bool nd_sio_bind(nd_sio_t *sio, const struct sockaddr *addr, size_t addrlen);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user