(The deleted if(!useSyslog) are superfluous since the code is already in an
if block)
--- ntop-original/util.c Tue Dec 11 17:05:24 2001
+++ ntop/util.c Fri Dec 14 11:57:04 2001
@@ -2152,12 +2152,10 @@
if(!useSyslog) {
strftime(theDate, 32, "%d/%b/%Y %H:%M:%S", localtime_r(&theTime,
&t));
if(traceLevel == DETAIL_TRACE_LEVEL) {
- if(!useSyslog)
printf("%s [%s:%d] ", theDate, file, line);
} else {
- if(!useSyslog)
printf("%s ", theDate);
}
}
===========================================================================
(spelling)
--- ntop-original/main.c Thu Dec 13 17:05:06 2001
+++ ntop/main.c Fri Dec 14 11:42:40 2001
@@ -375,5 +375,5 @@
pw = getpwnam(optarg);
if(pw == NULL) {
- printf("FATAL ERROR: Unkown user %s.\n", optarg);
+ printf("FATAL ERROR: Unknown user %s.\n", optarg);
exit(-1);
}
===========================================================================
(Move the web server port checks BEFORE doing the work for initIPServices
and initLogger - if we have bad parms, just do less work...)
--- ntop-original/main.c Thu Dec 13 17:05:06 2001
+++ ntop/main.c Fri Dec 14 13:19:46 2001
@@ -415,11 +415,4 @@
}
- initIPServices();
-
- snprintf(accessLogPath, sizeof(accessLogPath), "%s/%s",
- dbPath, DETAIL_ACCESS_LOG_FILE_PATH);
-
- initLogger(); /* Do not call this function before dbPath
- is initialized */
if(webPort == 0) {
#ifdef HAVE_OPENSSL
@@ -436,6 +429,4 @@
}
- /* ***************************** */
-
#ifdef HAVE_OPENSSL
if(sslPort == 0)
@@ -443,4 +434,13 @@
"use -W <https port> for enabling it\n");
#endif
+
+ initIPServices();
+
+ snprintf(accessLogPath, sizeof(accessLogPath), "%s/%s",
+ dbPath, DETAIL_ACCESS_LOG_FILE_PATH);
+
+ initLogger(); /* Do not call this function before dbPath
+ is initialized */
+ /* ***************************** */
initGlobalValues();
===========================================================================
===========================================================================
_______________________________________________
Ntop-dev mailing list
[EMAIL PROTECTED]
http://listmanager.unipi.it/mailman/listinfo/ntop-dev