Revision: 14322
Author: adrian.chadd
Date: Sun Oct 18 10:13:12 2009
Log: Flesh out the logfile helper basics, stolen from the logging daemon  
code.


http://code.google.com/p/lusca-cache/source/detail?r=14322

Added:
  /branches/LUSCA_HEAD/libloghelper/loghelper.h

=======================================
--- /dev/null
+++ /branches/LUSCA_HEAD/libloghelper/loghelper.h       Sun Oct 18 10:13:12 2009
@@ -0,0 +1,24 @@
+#ifndef        __LIBLOGHELPER_LOGHELPER_H__
+#define        __LIBLOGHELPER_LOGHELPER_H__
+
+struct _loghelper_buffer {
+       char *buf;
+       int size;
+       int len;
+       int written_len;
+       dlink_node node;
+};
+typedef struct loghelper_buffer loghelper_buffer_t;
+
+struct _loghelper_instance {
+       int rfd, wfd;                   /* read/write FDs to IPC helper */
+       char eol;                       /* whether we are currently at the "end 
of packet" */
+       pid_t pid;                      /* pid of helper */
+       int flush_pending;              /* whether a flush command is pending */
+       dlink_list bufs;                /* buffers to write */
+       int nbufs;                      /* number of buffers to write */
+       int last_warned;
+};
+typedef struct _loghelper_instance loghelper_instance_t;
+
+#endif

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"lusca-commit" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/lusca-commit?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to