linux.c: Implement the return-code protocol described.
[yaid] / yaid.h
diff --git a/yaid.h b/yaid.h
index ef3e726..0f4efd8 100644 (file)
--- a/yaid.h
+++ b/yaid.h
@@ -67,6 +67,7 @@
 #include <mLib/dstr.h>
 #include <mLib/fdflags.h>
 #include <mLib/fwatch.h>
+#include <mLib/macros.h>
 #include <mLib/mdwopt.h>
 #include <mLib/quis.h>
 #include <mLib/report.h>
@@ -248,8 +249,8 @@ struct query {
 /* Format and log MSG somewhere sensible, at the syslog(3) priority PRIO.
  * Prefix it with a description of the query Q, if non-null.
  */
-extern void logmsg(const struct query */*q*/,
-                  int /*prio*/, const char */*msg*/, ...);
+extern void PRINTF_LIKE(3, 4)
+  logmsg(const struct query */*q*/, int /*prio*/, const char */*msg*/, ...);
 
 /*----- System-specific connection identification code --------------------*/
 
@@ -330,8 +331,8 @@ extern int match_policy(const struct policy */*p*/,
 enum {
   T_OK,                                        /* Successful: results returned */
   T_EOL,                               /* End-of-line found immediately */
-  T_EOF,                               /* End-of-file found immediately */
-  T_ERROR                              /* Some kind of error occurred */
+  T_ERROR,                             /* Some kind of error occurred */
+  T_EOF                                        /* End-of-file found immediately */
 };
 
 /* A context for parsing a policy file. */