summaryrefslogtreecommitdiffstats
path: root/rsyslog.h
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2007-07-31 07:37:04 +0000
committerRainer Gerhards <rgerhards@adiscon.com>2007-07-31 07:37:04 +0000
commit4d162e6a580da3bbbe0f2da4696a77ad9da44161 (patch)
treec44fb8b4beba3a3fb3195be1afd9e4519ddb8c3b /rsyslog.h
parent1531dbee973e0f70def6ef94e7022adc02ca463f (diff)
downloadrsyslog-4d162e6a580da3bbbe0f2da4696a77ad9da44161.tar.gz
rsyslog-4d162e6a580da3bbbe0f2da4696a77ad9da44161.tar.xz
rsyslog-4d162e6a580da3bbbe0f2da4696a77ad9da44161.zip
- moved umask & file/dir creation mode parsing to cfsysline.c
- added macro for easy and consistent check of iRet return value
Diffstat (limited to 'rsyslog.h')
-rw-r--r--rsyslog.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/rsyslog.h b/rsyslog.h
index 149e589c..2badea3c 100644
--- a/rsyslog.h
+++ b/rsyslog.h
@@ -59,10 +59,16 @@ enum rsRetVal_ /** return value. All methods return this if not specified oth
RS_RET_DISABLE_ACTION = -2006, /**< action requests that it be disabled */
RS_RET_SUSPENDED = -2007, /**< something was suspended, not neccesarily an error */
RS_RET_RQD_TPLOPT_MISSING = -2008,/**< a required template option is missing */
+ RS_RET_INVALID_VALUE = -2009,/**< some value is invalid (e.g. user-supplied data) */
RS_RET_OK = 0 /**< operation successful */
};
typedef enum rsRetVal_ rsRetVal; /**< friendly type for global return value */
+/* some helpful macros to work with srRetVals.
+ * Be sure to call the to-be-returned variable always "iRet" and
+ * the function finalizer always "finalize_it".
+ */
+#define CHKiRet(code) if((iRet = code) != RS_RET_OK) goto finalize_it
/** Object ID. These are for internal checking. Each
* object is assigned a specific ID. This is contained in