summaryrefslogtreecommitdiff
path: root/sysdep/bsd
diff options
context:
space:
mode:
authorOndrej Zajicek <santiago@crfreenet.org>2013-06-29 22:55:41 +0200
committerOndrej Zajicek <santiago@crfreenet.org>2013-07-04 18:02:22 +0200
commitc6964c305b425b98aaf0492806a28b578d799d83 (patch)
tree55c7c52df882855abef78e4bd22e3dca4c18809c /sysdep/bsd
parent6ac4f87a2d661c739e55a63577e7bccf696c7abd (diff)
Makes krt.c much more readable.
Diffstat (limited to 'sysdep/bsd')
-rw-r--r--sysdep/bsd/krt-sock.c9
-rw-r--r--sysdep/bsd/krt-sys.h4
2 files changed, 6 insertions, 7 deletions
diff --git a/sysdep/bsd/krt-sock.c b/sysdep/bsd/krt-sock.c
index e970d6bd..cad0cfc9 100644
--- a/sysdep/bsd/krt-sock.c
+++ b/sysdep/bsd/krt-sock.c
@@ -681,15 +681,14 @@ static size_t kif_buflen = 4096;
void
krt_do_scan(struct krt_proto *p)
{
- krt_sysctl_scan((struct proto *)p, p->krt_pool, &krt_buffer, &krt_buflen, NET_RT_DUMP);
+ krt_sysctl_scan(&p->p, p->p.pool, &krt_buffer, &krt_buflen, NET_RT_DUMP);
}
void
kif_do_scan(struct kif_proto *p)
{
- struct proto *P = (struct proto *)p;
if_start_update();
- krt_sysctl_scan(P, P->pool, &kif_buffer, &kif_buflen, NET_RT_IFLIST);
+ krt_sysctl_scan(&p->p, p->p.pool, &kif_buffer, &kif_buflen, NET_RT_IFLIST);
if_end_update();
}
@@ -708,7 +707,7 @@ krt_sock_hook(sock *sk, int size UNUSED)
}
void
-krt_sys_start(struct krt_proto *x, int first UNUSED)
+krt_sys_start(struct krt_proto *x)
{
sock *sk_rt;
static int ks_open_tried = 0;
@@ -733,7 +732,7 @@ krt_sys_start(struct krt_proto *x, int first UNUSED)
}
void
-krt_sys_shutdown(struct krt_proto *x UNUSED, int last UNUSED)
+krt_sys_shutdown(struct krt_proto *x UNUSED)
{
if (!krt_buffer)
return;
diff --git a/sysdep/bsd/krt-sys.h b/sysdep/bsd/krt-sys.h
index 88915dde..5e4529c5 100644
--- a/sysdep/bsd/krt-sys.h
+++ b/sysdep/bsd/krt-sys.h
@@ -15,7 +15,7 @@
struct kif_params {
};
-struct kif_status {
+struct kif_state {
};
@@ -33,7 +33,7 @@ static inline void kif_sys_copy_config(struct kif_config *d UNUSED, struct kif_c
struct krt_params {
};
-struct krt_status {
+struct krt_state {
};