You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by sa...@apache.org on 2007/10/18 09:37:03 UTC
svn commit: r585892 - in /webservices/axis2/trunk/c/util:
include/axutil_log.h src/log.c
Author: samisa
Date: Thu Oct 18 00:37:02 2007
New Revision: 585892
URL: http://svn.apache.org/viewvc?rev=585892&view=rev
Log:
Fixed the lage file signal problem by ignoring the signal, need to improve the logic there
Also fixed the formatting
Modified:
webservices/axis2/trunk/c/util/include/axutil_log.h
webservices/axis2/trunk/c/util/src/log.c
Modified: webservices/axis2/trunk/c/util/include/axutil_log.h
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/util/include/axutil_log.h?rev=585892&r1=585891&r2=585892&view=diff
==============================================================================
--- webservices/axis2/trunk/c/util/include/axutil_log.h (original)
+++ webservices/axis2/trunk/c/util/include/axutil_log.h Thu Oct 18 00:37:02 2007
@@ -38,21 +38,8 @@
*/
/**
- *Examples
- *To write debug information to log
- *AXIS2_LOG_DEBUG(log,AXIS2_LOG_SI,"log this %s %d","test",123);
- *This would log
- *"log this test 123" into the log file
- *
- *similar macros are defined for different log levels: CRITICAL,ERROR,WARNING and INFO
- *
- *CRITICAL and ERROR logs are always written to file and other logs are written
- *depending on the log level set (log->level)
- */
-
- /**
- * \brief Axis2 log levels
- */
+ * Axis2 log levels.
+ */
typedef enum axutil_log_levels
{
@@ -76,18 +63,19 @@
} axutil_log_levels_t;
/**
- * \brief Axis2 log ops struct
- *
- * Encapsulator struct for ops of axutil_log
- */
+ * Axis2 log ops struct.
+ *
+ * Encapsulator struct for ops of axutil_log.
+ */
struct axutil_log_ops
{
/**
- * deletes the log
- * @return axis2_status_t AXIS2_SUCCESS on success else AXIS2_FAILURE
+ * Frees the log.
+ * @param allocator pointer allocator to be used to free the struct
+ * @param log pointer to log struct instance to be freed
+ * @return void
*/
-
void(
AXIS2_CALL
* free)(
@@ -95,11 +83,14 @@
struct axutil_log * log);
/**
- * writes to the log
- * @param buffer buffer to be written to log
- * @param size size of the buffer to be written to log
- * @return satus of the op. AXIS2_SUCCESS on success else AXIS2_FAILURE
- */
+ * Writes to the log.
+ * @param log pointer to log struct instance
+ * @param buffer buffer to be written to log
+ * @param level log level, one of axutil_log_levels enum values
+ * @param file name of the source file from which the log is written
+ * @param line line number of the source file from which the log is written
+ * @return void
+ */
void(
AXIS2_CALL
* write)(
@@ -111,14 +102,13 @@
};
/**
- * \brief Axis2 Log struct
- *
- * Log is the encapsulating struct for all log related data and ops
- */
+ * Axis2 Log struct.
+ * Log is the encapsulating struct for all log related data and operations.
+ */
struct axutil_log
{
- /** Log related ops */
+ /** Log related operations */
const axutil_log_ops_t *ops;
/** Log level */
Modified: webservices/axis2/trunk/c/util/src/log.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/util/src/log.c?rev=585892&r1=585891&r2=585892&view=diff
==============================================================================
--- webservices/axis2/trunk/c/util/src/log.c (original)
+++ webservices/axis2/trunk/c/util/src/log.c Thu Oct 18 00:37:02 2007
@@ -23,6 +23,7 @@
#include <axutil_log_default.h>
#include <axutil_file_handler.h>
#include <axutil_thread.h>
+#include <signal.h>
typedef struct axutil_log_impl axutil_log_impl_t;
@@ -116,6 +117,10 @@
fprintf(stderr, "cannot create log mutex \n");
return NULL;
}
+
+#ifndef WIN32
+ signal(SIGXFSZ, SIG_IGN);
+#endif
/* default log file is axis2.log */
if (stream_name)
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-cvs-help@ws.apache.org