lib

morphux C utility library
Log | Files | Refs | Submodules | README | LICENSE | git clone https://git.ne02ptzero.me/git/lib

commit becac250828d4310614afe74480b9ed2a533c1f6
parent 721c0d40859384b1617653e21057377959dcabf2
Author: Ne02ptzero <louis@ne02ptzero.me>
Date:   Tue, 16 May 2017 18:21:45 +0200

Add(Utils): Add safe string macro checking

Diffstat:
Minc/m_util.h | 3+++
1 file changed, 3 insertions(+), 0 deletions(-)

diff --git a/inc/m_util.h b/inc/m_util.h @@ -22,6 +22,9 @@ # include <sys/stat.h> # include <morphux.h> +# define STR_OR_EMPTY(str) (str ? str : "") +# define STR_NULL_OR_EMPTY(str) (str == NULL || (str != NULL && *str == '\0')) + /*! * \brief Delete a directory recursively *