izmjene za lintian
[ossec-hids.git] / src / headers / shared.h
index 4165c5b..87fda42 100755 (executable)
@@ -1,4 +1,5 @@
-/* @(#) $Id$ */
+/* @(#) $Id: ./src/headers/shared.h, 2011/09/08 dcid Exp $
+ */
 
 /* Copyright (C) 2009 Trend Micro Inc.
  * All rights reserved.
@@ -18,7 +19,7 @@
  *  The stack smashing protector defeats some BoF via: gcc -fstack-protector
  *  Reference: http://gcc.gnu.org/onlinedocs/gcc-4.1.2/cpp.pdf
  */
+
 #if defined(__GNUC__) && (((__GNUC__ == 4) && (__GNUC_MINOR__ >= 1) && (__GNUC_PATCHLEVEL__ >= 2)) || \
                           ((__GNUC__ == 4) && (__GNUC_MINOR__ >= 2)) || \
                            (__GNUC__ >= 5))
 #include <sys/socket.h>
 #include <sys/un.h>
 #else
+#include <winsock2.h>
 #include <windows.h>
-#include <winsock.h>
 #include <io.h>
+#include <ws2tcpip.h>
+#include <shlwapi.h>
 #endif
 
 #include <time.h>
@@ -175,24 +178,24 @@ char *__local_name;
 /*** These functions will exit on error. No need to check return code ***/
 
 /* for calloc: x = calloc(4,sizeof(char)) -> os_calloc(4,sizeof(char),x) */
-#define os_calloc(x,y,z) (z = calloc(x,y))?(void)1:ErrorExit(MEM_ERROR, ARGV0) 
+#define os_calloc(x,y,z) ((z = calloc(x,y)))?(void)1:ErrorExit(MEM_ERROR, ARGV0)
 
-#define os_strdup(x,y) (y = strdup(x))?(void)1:ErrorExit(MEM_ERROR, ARGV0)
+#define os_strdup(x,y) ((y = strdup(x)))?(void)1:ErrorExit(MEM_ERROR, ARGV0)
 
-#define os_malloc(x,y) (y = malloc(x))?(void)1:ErrorExit(MEM_ERROR, ARGV0)
+#define os_malloc(x,y) ((y = malloc(x)))?(void)1:ErrorExit(MEM_ERROR, ARGV0)
 
 #define os_free(x) (x)?free(x):merror("free a null")
 
-#define os_realloc(x,y,z) (z = realloc(x,y))?(void)1:ErrorExit(MEM_ERROR, ARGV0)
+#define os_realloc(x,y,z) ((z = realloc(x,y)))?(void)1:ErrorExit(MEM_ERROR, ARGV0)
 
 #define os_clearnl(x,p) if((p = strrchr(x, '\n')))*p = '\0';
 
 #ifdef CLIENT
     #define isAgent 1
 #else
-    #define isAgent 0    
+    #define isAgent 0
 #endif
-        
+
 
 
 #include "debug_op.h"
@@ -216,13 +219,15 @@ char *__local_name;
 #include "file-queue.h"
 #include "read-agents.h"
 #include "report_op.h"
+#include "string_op.h"
 
 #include "os_xml/os_xml.h"
 #include "os_regex/os_regex.h"
 
 #include "error_messages/error_messages.h"
+#include "custom_output_search.h"
 
 
 #endif /* __SHARED_H */
-                              
+
 /* EOF */