diff src/event/ngx_event.h @ 218:05592fd7a436

nginx-0.0.1-2004-01-05-23:55:48 import
author Igor Sysoev <igor@sysoev.ru>
date Mon, 05 Jan 2004 20:55:48 +0000
parents e1c815be05ae
children 5d4f49dc8de5
line wrap: on
line diff
--- a/src/event/ngx_event.h
+++ b/src/event/ngx_event.h
@@ -20,6 +20,14 @@ typedef struct {
 #endif
 
 
+typedef enum {
+     NGX_ERROR_CRIT = 0,
+     NGX_ERROR_ERR,
+     NGX_ERROR_INFO,
+     NGX_ERROR_IGNORE_ECONNRESET
+} ngx_event_log_error_e;
+
+
 struct ngx_event_s {
     void            *data;
     /* TODO rename to handler */
@@ -36,8 +44,8 @@ struct ngx_event_s {
     /*
      * The inline of "ngx_rbtree_t  rbtree;".
      *
-     * It allows to pack the rbtree_color and the variuos event bit flags into
-     * the single "int".  We also use "unsigned char" and then "usigned short"
+     * It allows to pack the rbtree_color and the various event bit flags into
+     * the single "int".  We also use "unsigned char" and then "unsigned short"
      * because otherwise MSVC 6.0 uses an additional "int" for the bit flags.
      * We use "char rbtree_color" instead of "unsigned int rbtree_color:1"
      * because it preserves the bits order on the big endian platforms.
@@ -62,14 +70,16 @@ struct ngx_event_s {
      */
     unsigned char    active:1;
 
+    unsigned char    disabled:1;
+
     /* the ready event; in aio mode 0 means that no operation can be posted */
     unsigned char    ready:1;
 
     /* aio operation is complete */
     unsigned char    complete:1;
 
-    unsigned char    eof:1;
-    unsigned char    error:1;
+    unsigned short   eof:1;
+    unsigned short   error:1;
 
     unsigned short   timedout:1;
     unsigned short   timer_set:1;
@@ -78,7 +88,7 @@ struct ngx_event_s {
 
     unsigned short   read_discarded:1;
 
-    unsigned short   ignore_econnreset:1;
+    unsigned short   log_error:2;  /* ngx_event_log_error_e */
     unsigned short   unexpected_eof:1;
 
     unsigned short   deferred_accept:1;
@@ -371,6 +381,9 @@ int ngx_event_post_acceptex(ngx_listenin
 #endif
 
 
+/* used in ngx_log_debugX() */
+#define ngx_event_ident(p)  ((ngx_connection_t *) (p))->fd
+
 
 #include <ngx_event_timer.h>