File tree Expand file tree Collapse file tree 1 file changed +15
-13
lines changed Expand file tree Collapse file tree 1 file changed +15
-13
lines changed Original file line number Diff line number Diff line change 4
4
#include <pthread.h>
5
5
#include "config.h"
6
6
7
+
8
+ #ifdef DEBUG
9
+
10
+ #include <stdio.h>
11
+ #define console_log_mod (MODIFIER , LOGDATA ) fprintf(stderr, MODIFIER, LOGDATA)
12
+ #define console_log (LOGDATA ) fprintf(stderr, "%s\n", LOGDATA)
13
+
14
+ #else
15
+
16
+ #define console_log_mod (MODIFIER , LOGDATA )
17
+ #define console_log (LOGDATA )
18
+
19
+ #endif /* end of DEBUG */
20
+
21
+
7
22
#define linked_list_add (BUFFER , BLOCK ) \
8
23
{ \
9
24
pthread_mutex_lock(&(BUFFER.mutex)); \
@@ -38,17 +53,4 @@ typedef void * (*thread_worker_t) (void *);
38
53
tid_t thread_start (thread_worker_t , void * );
39
54
void thread_stop (tid_t );
40
55
41
- #ifdef DEBUG
42
-
43
- #include <stdio.h>
44
- #define console_log_mod (MODIFIER , LOGDATA ) printf(MODIFIER, LOGDATA)
45
- #define console_log (LOGDATA ) printf("%s\n", LOGDATA)
46
-
47
- #else
48
-
49
- #define console_log_mod (MODIFIER , LOGDATA )
50
- #define console_log (LOGDATA )
51
-
52
- #endif /* end of DEBUG */
53
-
54
56
#endif /* end of include guard: UTIL_H_RSWIA2KL */
You can’t perform that action at this time.
0 commit comments