mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-15 20:32:18 +00:00
2003-07-8 Chris Andrews <chris@nodnol.org>
* zebra/kernel_socket.c: Update for new zebrad global struct * zebra/ipforward_solaris.c: Add missing privs.h include. Uncomment /dev/ip define. * lib/zebra.h: Add typedefs for SunOS.
This commit is contained in:
parent
0c14ad88aa
commit
9bcdb63892
@ -28,6 +28,9 @@ Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
|||||||
#ifdef SUNOS_5
|
#ifdef SUNOS_5
|
||||||
#define _XPG4_2
|
#define _XPG4_2
|
||||||
#define __EXTENSIONS__
|
#define __EXTENSIONS__
|
||||||
|
typedef unsigned int u_int32_t;
|
||||||
|
typedef unsigned short u_int16_t;
|
||||||
|
typedef unsigned char u_int8_t;
|
||||||
#endif /* SUNOS_5 */
|
#endif /* SUNOS_5 */
|
||||||
|
|
||||||
#ifndef HAVE_SOCKLEN_T
|
#ifndef HAVE_SOCKLEN_T
|
||||||
|
@ -24,6 +24,8 @@
|
|||||||
#include "log.h"
|
#include "log.h"
|
||||||
#include "prefix.h"
|
#include "prefix.h"
|
||||||
|
|
||||||
|
#include "privs.h"
|
||||||
|
|
||||||
/*
|
/*
|
||||||
** Solaris should define IP_DEV_NAME in <inet/ip.h>, but we'll save
|
** Solaris should define IP_DEV_NAME in <inet/ip.h>, but we'll save
|
||||||
** configure.in changes for another day. We can use the same device
|
** configure.in changes for another day. We can use the same device
|
||||||
@ -33,11 +35,11 @@
|
|||||||
#ifndef IP_DEV_NAME
|
#ifndef IP_DEV_NAME
|
||||||
#define IP_DEV_NAME "/dev/ip"
|
#define IP_DEV_NAME "/dev/ip"
|
||||||
#endif
|
#endif
|
||||||
/*
|
|
||||||
|
|
||||||
extern struct zebra_privs_t zserv_privs;
|
extern struct zebra_privs_t zserv_privs;
|
||||||
|
|
||||||
** This is a limited ndd style function that operates one integer
|
/* This is a limited ndd style function that operates one integer
|
||||||
** value only. Errors return -1. ND_SET commands return 0 on
|
** value only. Errors return -1. ND_SET commands return 0 on
|
||||||
** success. ND_GET commands return the value on success (which could
|
** success. ND_GET commands return the value on success (which could
|
||||||
** be -1 and be confused for an error). The parameter is the string
|
** be -1 and be confused for an error). The parameter is the string
|
||||||
|
@ -38,6 +38,7 @@
|
|||||||
#include "zebra/debug.h"
|
#include "zebra/debug.h"
|
||||||
|
|
||||||
extern struct zebra_privs_t zserv_privs;
|
extern struct zebra_privs_t zserv_privs;
|
||||||
|
extern struct zebra_t zebrad;
|
||||||
|
|
||||||
/* Socket length roundup function. */
|
/* Socket length roundup function. */
|
||||||
#define ROUNDUP(a) \
|
#define ROUNDUP(a) \
|
||||||
@ -679,8 +680,6 @@ rtm_write (int message,
|
|||||||
#include "thread.h"
|
#include "thread.h"
|
||||||
#include "zebra/zserv.h"
|
#include "zebra/zserv.h"
|
||||||
|
|
||||||
extern struct thread_master *master;
|
|
||||||
|
|
||||||
/* For debug purpose. */
|
/* For debug purpose. */
|
||||||
void
|
void
|
||||||
rtmsg_debug (struct rt_msghdr *rtm)
|
rtmsg_debug (struct rt_msghdr *rtm)
|
||||||
@ -764,7 +763,7 @@ kernel_read (struct thread *thread)
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
thread_add_read (master, kernel_read, NULL, sock);
|
thread_add_read (zebrad.master, kernel_read, NULL, sock);
|
||||||
|
|
||||||
if (IS_ZEBRA_DEBUG_KERNEL)
|
if (IS_ZEBRA_DEBUG_KERNEL)
|
||||||
rtmsg_debug (&buf.r.rtm);
|
rtmsg_debug (&buf.r.rtm);
|
||||||
@ -820,7 +819,7 @@ routing_socket ()
|
|||||||
zlog_err ("routing_socket: Can't lower privileges");
|
zlog_err ("routing_socket: Can't lower privileges");
|
||||||
|
|
||||||
/* kernel_read needs rewrite. */
|
/* kernel_read needs rewrite. */
|
||||||
thread_add_read (master, kernel_read, NULL, routing_sock);
|
thread_add_read (zebrad.master, kernel_read, NULL, routing_sock);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Exported interface function. This function simply calls
|
/* Exported interface function. This function simply calls
|
||||||
|
Loading…
Reference in New Issue
Block a user