diff options
author | Hai Nguyen <379079+chaoticbob@users.noreply.github.com> | 2021-11-11 20:29:02 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-11-11 20:29:02 -0500 |
commit | 173ae4d9bbcc8fd0307bea9f126cb50619ceff23 (patch) | |
tree | ac4986f3fb3eabcf8effdcfcee1df91828d8690d | |
parent | cc937caab141d889c9c9dff572c5a6854d5cf9b4 (diff) | |
parent | 9b0ed5471f345655f7c9e52c152a1adf618cdade (diff) | |
download | SPIRV-Reflect-173ae4d9bbcc8fd0307bea9f126cb50619ceff23.tar.gz |
Merge pull request #129 from blackbird806/patch-1
Removed null test in SafeFree Macro
-rw-r--r-- | spirv_reflect.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/spirv_reflect.c b/spirv_reflect.c index 1c94a2e..dc45bd5 100644 --- a/spirv_reflect.c +++ b/spirv_reflect.c @@ -235,12 +235,10 @@ static uint32_t RoundUp( #define IsNotNull(ptr) \ (ptr != NULL) -#define SafeFree(ptr) \ - { \ - if (ptr != NULL) { \ - free((void*)ptr); \ - ptr = NULL; \ - } \ +#define SafeFree(ptr) \ + { \ + free((void*)ptr); \ + ptr = NULL; \ } static int SortCompareUint32( |