Commit a47272c4 authored by 's avatar
Browse files

Fixed bugs in adm_ctrl compilation.


git-svn-id: file:///home/svn/mapi/trunk@354 8d5bb341-7cf1-0310-8cf6-ba355fef3186
parent e6770ea7
......@@ -10,13 +10,13 @@ LIB_DIR=-L/usr/local/lib
DEBUG=1
#DAG cards
WITH_DAG=1
WITH_DAG=0
#COMBO6 cards
WITH_COMBO6=0
#Distributed MAPI functionality
WITH_DIMAPI=0
WITH_DIMAPI=1
#MAPI function statistics
#With this pkt counters for each function is enabled
......@@ -33,7 +33,7 @@ WITH_MODIFY_PKTS=0
WITH_ANONYMIZATION=0
#Support for application-level filtering (mostly P2P traffic identification)
WITH_TRACKING=0
WITH_TRACKING=1
#Ipfix flow record generation
WITH_IPFIX=0
......@@ -52,7 +52,7 @@ WITH_ETHEREAL=0
WITH_OPTIMIZED_BPF_FILTER=0
# ADMISSION CONTROL
WITH_ADMISSION_CONTROL=0
WITH_ADMISSION_CONTROL=1
WITH_RESOURCE_CONTROL=0
ifeq ($(WITH_DAG),1)
......@@ -68,11 +68,11 @@ endif
ifeq ($(WITH_ADMISSION_CONTROL),1)
ADMCTRLCL_LDADD=-ladmctrlcl -lssl
ADMCTRLCL_HEADERS=admctrl_cl.h slist.h config.h
ADMCTRLCL_HEADERS=admctrl_cl.h ./adm_ctrl/lib/slist.h ./adm_ctrl/config.h
ADMCTRLCL_BYTESTREAM_H=bytestream.h
ADMCTRLCL_OBJS=admctrl_cl.o slist.o
ADMCTRLCL_OBJS=admctrl_cl.o ./adm_ctrl/lib/slist.o
ADMCTRLCL_CFLAGS=-DWITH_ADMISSION_CONTROL
KEYNOTE_CFLAGS=-I/usr/local/keynote
#KEYNOTE_CFLAGS=-I/usr/local/keynote
KEYNOTE_LDADD=-L/usr/local/keynote -lkeynote -lm -lcrypto
endif
......
......@@ -3,7 +3,8 @@ include Makefile.in
CC=gcc
CFLAGS=-Wall -Wsign-compare -Wpointer-arith -Wnested-externs \
-Wmissing-declarations -Wcast-align -D_GNU_SOURCE -Werror
-Wmissing-declarations -Wcast-align -D_GNU_SOURCE
# -Werror
LIB_OBJS=lib/string_buf.o lib/darray.o lib/stack.o
LIB_HEADERS=lib/stack.h lib/string_buf.h lib/darray.h
......@@ -27,7 +28,8 @@ ifeq (${WITH_SYSLOG},1)
CFLAGS += -DSYSLOG
endif
CFLAGS := ${CFLAGS} -DDEBUG=${ADMCTRL_DEBUG} ${INCLUDE}
CFLAGS := ${CFLAGS} ${INCLUDE}
#-DDEBUG=${ADMCTRL_DEBUG} ${INCLUDE}
all: libs ${TARGETS}
......
......@@ -8,9 +8,9 @@
#include <signal.h>
#include <stdlib.h>
#include <string.h>
#ifdef SYSLOG
//#ifdef SYSLOG
#include <syslog.h>
#endif
//#endif
#include "shm_sync.h"
#include "shm.h"
......@@ -261,7 +261,7 @@ main(int argc,char **argv)
chdir("/");
umask(0);
#if DEBUG == 0
#ifndef DEBUG
for(i = 0 ; i < NOFILE ; i++)
close(i);
#endif
......
......@@ -16,7 +16,7 @@
#include "admctrl_cl.h"
#include "mapidlib.h"
#include "debug.h"
#include "slist.h"
#include "adm_ctrl/lib/slist.h"
#ifndef MAX
#define MAX(x,y) (x>y)? x : y
......@@ -231,8 +231,7 @@ flow_destroy(void *p)
int
admctrl_remove_flow(unsigned int fd)
{
return (slist_search_and_delete2(&client_list,flow_comp,(void *)fd,
flow_destroy) > 0)? 0 : -1;
return (slist_search_and_delete(&client_list,flow_comp,(void *)fd, 0/*flow_destroy*/) > 0)? 0 : -1;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment