mirror of
https://github.com/rofl0r/proxychains-ng.git
synced 2024-10-31 17:18:47 +00:00
d0abc93c74
instead of allocating memory in the child, we now use the allocator thread to do all the necessary allocations himself. additionally we provide a clean API to query the ip <-> dns mapping. these functions connect via a pipe to the allocator thread, and exchange messages. further cleanup is needed, but it seems to work so far. thread-safety is not yet guaranteed. closes #1
11 lines
258 B
C
11 lines
258 B
C
#ifndef MUTEX_H
|
|
#define MUTEX_H
|
|
|
|
#include <pthread.h>
|
|
# define MUTEX_LOCK(x) pthread_mutex_lock(x)
|
|
# define MUTEX_UNLOCK(x) pthread_mutex_unlock(x)
|
|
# define MUTEX_INIT(x) pthread_mutex_init(x, NULL)
|
|
# define MUTEX_DESTROY(x) pthread_mutex_destroy(x)
|
|
|
|
#endif
|