mirror of
https://github.com/ntop/n2n.git
synced 2024-09-20 00:51:10 +02:00
Compilation fixes
This commit is contained in:
parent
268308607d
commit
50755005e0
4
Makefile
4
Makefile
|
@ -16,8 +16,8 @@ N2N_DEFINES=
|
|||
N2N_OBJS_OPT=
|
||||
LIBS_EDGE_OPT=
|
||||
|
||||
N2N_OPTION_AES?="yes"
|
||||
#N2N_OPTION_AES=no
|
||||
#N2N_OPTION_AES?="yes"
|
||||
N2N_OPTION_AES=no
|
||||
|
||||
ifeq ($(N2N_OPTION_AES), "yes")
|
||||
N2N_DEFINES+=-DN2N_HAVE_AES
|
||||
|
|
9
edge.c
9
edge.c
|
@ -174,9 +174,8 @@ static void help() {
|
|||
|
||||
/* *************************************************** */
|
||||
|
||||
static int setOption(int optkey, char *optarg, edge_conf_t *ec, n2n_edge_t *eee) {
|
||||
|
||||
//traceEvent(TRACE_NORMAL, "Option %c = %s", optkey, optarg ? optarg : "");
|
||||
static int setOption(int optkey, char *optargument, edge_conf_t *ec, n2n_edge_t *eee) {
|
||||
//traceEvent(TRACE_NORMAL, "Option %c = %s", optkey, optargument ? optargument : "");
|
||||
|
||||
switch(optkey) {
|
||||
case'K':
|
||||
|
@ -185,7 +184,7 @@ static int setOption(int optkey, char *optarg, edge_conf_t *ec, n2n_edge_t *eee)
|
|||
fprintf(stderr, "Error: -K and -k options are mutually exclusive.\n");
|
||||
exit(1);
|
||||
} else {
|
||||
strncpy(eee->keyschedule, optarg, N2N_PATHNAME_MAXLEN-1);
|
||||
strncpy(eee->keyschedule, optargument, N2N_PATHNAME_MAXLEN-1);
|
||||
/* strncpy does not add NULL if the source has no NULL. */
|
||||
eee->keyschedule[N2N_PATHNAME_MAXLEN-1] = 0;
|
||||
|
||||
|
@ -199,7 +198,7 @@ static int setOption(int optkey, char *optarg, edge_conf_t *ec, n2n_edge_t *eee)
|
|||
{
|
||||
scan_address(ec->ip_addr, N2N_NETMASK_STR_SIZE,
|
||||
ec->ip_mode, N2N_IF_MODE_SIZE,
|
||||
optarg);
|
||||
optargument);
|
||||
break;
|
||||
}
|
||||
|
||||
|
|
|
@ -894,7 +894,7 @@ static void readFromMgmtSocket(n2n_edge_t * eee, int * keep_running) {
|
|||
"Statistics for edge\n");
|
||||
|
||||
msg_len += snprintf((char *)(udp_buf+msg_len), (N2N_PKT_BUF_SIZE-msg_len),
|
||||
"uptime %llu\n",
|
||||
"uptime %lu\n",
|
||||
time(NULL) - eee->start_time);
|
||||
|
||||
msg_len += snprintf((char *)(udp_buf+msg_len), (N2N_PKT_BUF_SIZE-msg_len),
|
||||
|
@ -921,7 +921,7 @@ static void readFromMgmtSocket(n2n_edge_t * eee, int * keep_running) {
|
|||
(unsigned int)peer_list_size(eee->known_peers));
|
||||
|
||||
msg_len += snprintf((char *)(udp_buf+msg_len), (N2N_PKT_BUF_SIZE-msg_len),
|
||||
"last super:%llu(%lld sec ago) p2p:%llu(%lld sec ago)\n",
|
||||
"last super:%lu (%ld sec ago) p2p:%lu (%ld sec ago)\n",
|
||||
eee->last_sup, (now-eee->last_sup), eee->last_p2p, (now-eee->last_p2p));
|
||||
|
||||
traceEvent(TRACE_DEBUG, "mgmt status sending: %s", udp_buf);
|
||||
|
|
|
@ -20,8 +20,6 @@
|
|||
#include "n2n_transforms.h"
|
||||
|
||||
#if defined(N2N_HAVE_AES)
|
||||
|
||||
|
||||
#include "openssl/aes.h"
|
||||
#ifndef _MSC_VER
|
||||
/* Not included in Visual Studio 2008 */
|
||||
|
|
Loading…
Reference in New Issue
Block a user