[Openvas-commits] r209 - in trunk/openvas-server: . include openvasd

scm-commit@wald.intevation.org scm-commit at wald.intevation.org
Fri May 25 01:26:42 CEST 2007


Author: jan
Date: 2007-05-25 01:26:39 +0200 (Fri, 25 May 2007)
New Revision: 209

Modified:
   trunk/openvas-server/ChangeLog
   trunk/openvas-server/include/ntcompat.h
   trunk/openvas-server/openvasd/log.c
   trunk/openvas-server/openvasd/openvasd.c
   trunk/openvas-server/openvasd/pluginload.c
   trunk/openvas-server/openvasd/preferences.c
Log:
* include/ntcompat.h: Remove now useless emtpy defines for
  PlugExport, DllExport, DllImport and ExtFunc. Remove
  alias print_error for printf which was not used strictly
  anyway.

* openvasd/log.c, openvasd/openvasd.c, openvasd/pluginload.c,
  openvasd/preferences.c: Replaced print_error by printf.


Modified: trunk/openvas-server/ChangeLog
===================================================================
--- trunk/openvas-server/ChangeLog	2007-05-24 23:05:50 UTC (rev 208)
+++ trunk/openvas-server/ChangeLog	2007-05-24 23:26:39 UTC (rev 209)
@@ -1,5 +1,15 @@
 2007-05-25  Jan-Oliver Wagner <jan-oliver.wagner at intevation.de>
 
+	* include/ntcompat.h: Remove now useless emtpy defines for
+	PlugExport, DllExport, DllImport and ExtFunc. Remove
+	alias print_error for printf which was not used strictly
+	anyway.
+
+	* openvasd/log.c, openvasd/openvasd.c, openvasd/pluginload.c,
+	openvasd/preferences.c: Replaced print_error by printf.
+
+2007-05-25  Jan-Oliver Wagner <jan-oliver.wagner at intevation.de>
+
 	* include/includes.h, include/openvas-devel.h, openvasd/sighand.c:
 	Remove any consideration of NESSUSNT.
 

Modified: trunk/openvas-server/include/ntcompat.h
===================================================================
--- trunk/openvas-server/include/ntcompat.h	2007-05-24 23:05:50 UTC (rev 208)
+++ trunk/openvas-server/include/ntcompat.h	2007-05-24 23:26:39 UTC (rev 209)
@@ -101,12 +101,4 @@
 #define LIB_LAST_ERROR dlerror
 #define CLOSE_LIBRARY(x) dlclose(x)
 
-
-#define print_error printf
-
-#define PlugExport
-#define DllExport
-#define DllImport
-#define ExtFunc
-
 #endif /* defined(NESSUS_NT_COMPAT_H) */

Modified: trunk/openvas-server/openvasd/log.c
===================================================================
--- trunk/openvas-server/openvasd/log.c	2007-05-24 23:05:50 UTC (rev 208)
+++ trunk/openvas-server/openvasd/log.c	2007-05-24 23:26:39 UTC (rev 209)
@@ -91,7 +91,7 @@
       if(fd < 0)
       {
        perror("log_init():open ");
-       print_error("Could not open the logfile, using stderr\n");
+       printf("Could not open the logfile, using stderr\n");
        log = stderr;
       }
       

Modified: trunk/openvas-server/openvasd/openvasd.c
===================================================================
--- trunk/openvas-server/openvasd/openvasd.c	2007-05-24 23:05:50 UTC (rev 208)
+++ trunk/openvas-server/openvasd/openvasd.c	2007-05-24 23:26:39 UTC (rev 209)
@@ -1208,7 +1208,7 @@
 	  break;
 
 	case 'v' :
-	  print_error("openvasd (%s) %s for %s\n(C) 1998 - 2004 Renaud Deraison <deraison at nessus.org>\n\n", 
+	  printf("openvasd (%s) %s for %s\n(C) 1998 - 2004 Renaud Deraison <deraison at nessus.org>\n\n", 
 		 PROGNAME,OPENVAS_VERSION, OVS_OS_NAME);
 	  DO_EXIT(0);
 	  break;

Modified: trunk/openvas-server/openvasd/pluginload.c
===================================================================
--- trunk/openvas-server/openvasd/pluginload.c	2007-05-24 23:05:50 UTC (rev 208)
+++ trunk/openvas-server/openvasd/pluginload.c	2007-05-24 23:26:39 UTC (rev 209)
@@ -170,14 +170,14 @@
 #ifdef DEBUG
       log_write("%s:%d : folder == NULL\n", __FILE__, __LINE__);
 #endif
-      print_error("could not determine the value of <plugins_folder>. Check %s\n",
+      printf("could not determine the value of <plugins_folder>. Check %s\n",
       	(char *)arg_get_value(preferences, "config_file"));
       return plugins;
     }
 
   if((dir = opendir(folder)) == NULL)
     {
-      print_error("Couldn't open the directory called \"%s\" - %s\nCheck %s\n", 
+      printf("Couldn't open the directory called \"%s\" - %s\nCheck %s\n", 
       		   folder,
 		   strerror(errno),
       		   (char *)arg_get_value(preferences, "config_file"));

Modified: trunk/openvas-server/openvasd/preferences.c
===================================================================
--- trunk/openvas-server/openvasd/preferences.c	2007-05-24 23:05:50 UTC (rev 208)
+++ trunk/openvas-server/openvasd/preferences.c	2007-05-24 23:26:39 UTC (rev 209)
@@ -179,16 +179,16 @@
 	if(!(fd = fopen(filename, "r"))) {
 	 if(errno == EACCES)
 	 {
-	  print_error(
+	  printf(
 	  	"The OpenVAS daemon doesn't have the right to read %s\n", filename);
 	  DO_EXIT(1);
 	 }
 
 #ifdef DEBUG
-	  print_error("Couldn't find any prefs file... Creating a new one...\n");
+	  printf("Couldn't find any prefs file... Creating a new one...\n");
 #endif 
 	  if(preferences_new(filename)){
-	    print_error("Error creating %s\n", filename);
+	    printf("Error creating %s\n", filename);
 	    exit(1);
 	    arg_add_value(prefs, "plugins_folder", ARG_STRING,
 			  strlen("./plugins"), "./plugins");
@@ -198,7 +198,7 @@
 	    if(!(fd = fopen(filename, "r")))
 	      {
 	        perror("preferences_process():open ");
-		print_error("Could not open %s -- now quitting\n", filename);
+		printf("Could not open %s -- now quitting\n", filename);
 		DO_EXIT(2);
 	      }
 	}



More information about the Openvas-commits mailing list