diff options
Diffstat (limited to 'examples/redis-unstable/src/debugmacro.h')
| -rw-r--r-- | examples/redis-unstable/src/debugmacro.h | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/examples/redis-unstable/src/debugmacro.h b/examples/redis-unstable/src/debugmacro.h deleted file mode 100644 index c977381..0000000 --- a/examples/redis-unstable/src/debugmacro.h +++ /dev/null | |||
| @@ -1,26 +0,0 @@ | |||
| 1 | /* This file contains debugging macros to be used when investigating issues. | ||
| 2 | * | ||
| 3 | * ----------------------------------------------------------------------------- | ||
| 4 | * | ||
| 5 | * Copyright (c) 2016-Present, Redis Ltd. | ||
| 6 | * All rights reserved. | ||
| 7 | * | ||
| 8 | * Licensed under your choice of (a) the Redis Source Available License 2.0 | ||
| 9 | * (RSALv2); or (b) the Server Side Public License v1 (SSPLv1); or (c) the | ||
| 10 | * GNU Affero General Public License v3 (AGPLv3). | ||
| 11 | */ | ||
| 12 | |||
| 13 | #ifndef _REDIS_DEBUGMACRO_H_ | ||
| 14 | #define _REDIS_DEBUGMACRO_H_ | ||
| 15 | |||
| 16 | #include <stdio.h> | ||
| 17 | #define D(...) \ | ||
| 18 | do { \ | ||
| 19 | FILE *fp = fopen("/tmp/log.txt","a"); \ | ||
| 20 | fprintf(fp,"%s:%s:%d:\t", __FILE__, __func__, __LINE__); \ | ||
| 21 | fprintf(fp,__VA_ARGS__); \ | ||
| 22 | fprintf(fp,"\n"); \ | ||
| 23 | fclose(fp); \ | ||
| 24 | } while (0) | ||
| 25 | |||
| 26 | #endif /* _REDIS_DEBUGMACRO_H_ */ | ||
