diff options
author | Mikhail Burakov <mburakov@mailbox.org> | 2023-04-08 13:49:13 +0200 |
---|---|---|
committer | Mikhail Burakov <mburakov@mailbox.org> | 2023-04-09 10:26:16 +0200 |
commit | b4996b76e99ab602ff87df31d61074cfa72f9f61 (patch) | |
tree | d8ec2684929e1e2b98394d31896b1e048b8adaa3 /util.h | |
parent | 0fe1d5648f5ee5f1548eb887e96ca149f9e6481c (diff) |
Get rid of auto variables
Diffstat (limited to 'util.h')
-rw-r--r-- | util.h | 8 |
1 files changed, 0 insertions, 8 deletions
@@ -22,17 +22,9 @@ #define STR(x) STR_IMPL(x) #define LOG(fmt, ...) \ fprintf(stderr, __FILE__ ":" STR(__LINE__) " " fmt "\n", ##__VA_ARGS__) -#define AUTO(x) x __attribute__((__cleanup__(x##Destroy))) -#define RELEASE(x) Release((void**)&x) #define LENGTH(x) (sizeof(x) / sizeof *(x)) #define MAX(a, b) ((a) > (b) ? (a) : (b)) #define MIN(a, b) ((a) < (b) ? (a) : (b)) #define _(...) __VA_ARGS__ -static inline void* Release(void** x) { - void* result = *x; - *x = 0; - return result; -} - #endif // STREAMER_UTIL_H_ |