logic: interprocess utility

Added basic interprocess utility
This commit is contained in:
wrongway88
2017-02-21 17:12:35 +01:00
parent 9673685165
commit 1fbc16e098
16 changed files with 1066 additions and 0 deletions
@@ -0,0 +1,15 @@
#ifndef INTERPROCESS_UTILITY_H
#define INTERPROCESS_UTILITY_H
// requires a bool field 'm_initialized' to be defined
// if 'm_initialized' is false, the value '__retVal__' will be returned
// '__retVal__' is not required
#define IF_INITIALIZED(__retVal__) \
if(m_initialized == false) \
{ \
LOG_ERROR_STREAM(<< "not initialized"); \
return __retVal__; \
} \
else \
#endif // INTERPROCESS_UTILITY_H