Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 583730
Collapse All | Expand All

(-)a/src/common/compat.c (-2 / +2 lines)
Lines 19-25 Link Here
19
19
20
#include "compat.h"
20
#include "compat.h"
21
21
22
#if (defined(__GLIBC__) || defined(__FreeBSD__) || defined(__darwin__) || defined(__NetBSD__))
22
#if (defined(__GLIBC__) || defined(__linux__) || defined(__FreeBSD__) || defined(__darwin__) || defined(__NetBSD__))
23
23
24
/*
24
/*
25
 * Initialize a pthread mutex. This never fails.
25
 * Initialize a pthread mutex. This never fails.
Lines 96-99 void tsocks_once(tsocks_once_t *o, void (*init_routine)(void)) Link Here
96
	tsocks_mutex_unlock(&o->mutex);
96
	tsocks_mutex_unlock(&o->mutex);
97
}
97
}
98
98
99
#endif /* __GLIBC__, __darwin__, __FreeBSD__, __NetBSD__ */
99
#endif /* __GLIBC__, __linux__, __darwin__, __FreeBSD__, __NetBSD__ */
(-)a/src/common/compat.h (-2 / +2 lines)
Lines 22-28 Link Here
22
#define __darwin__	1
22
#define __darwin__	1
23
#endif
23
#endif
24
24
25
#if (defined(__GLIBC__) || defined(__FreeBSD__) || defined(__darwin__) || defined(__NetBSD__))
25
#if (defined(__GLIBC__) || defined(__linux__) || defined(__FreeBSD__) || defined(__darwin__) || defined(__NetBSD__))
26
26
27
#define RTLD_NEXT	((void *) -1)
27
#define RTLD_NEXT	((void *) -1)
28
28
Lines 55-61 void tsocks_once(tsocks_once_t *o, void (*init_routine)(void)); Link Here
55
55
56
#else
56
#else
57
#error "OS not supported."
57
#error "OS not supported."
58
#endif /* __GLIBC__, __darwin__, __FreeBSD__, __NetBSD__ */
58
#endif /* __GLIBC__, __linux__, __darwin__, __FreeBSD__, __NetBSD__ */
59
59
60
#if defined(__linux__)
60
#if defined(__linux__)
61
#include <unistd.h>
61
#include <unistd.h>
(-)a/src/common/ref.h (-2 / +2 lines)
Lines 26-32 struct ref { Link Here
26
	long count;
26
	long count;
27
};
27
};
28
28
29
#if (defined(__GLIBC__) || defined(__FreeBSD__) || defined(__darwin__) || defined(__NetBSD__))
29
#if (defined(__GLIBC__) || defined(__linux__) || defined(__FreeBSD__) || defined(__darwin__) || defined(__NetBSD__))
30
30
31
/*
31
/*
32
 * Get a reference by incrementing the refcount.
32
 * Get a reference by incrementing the refcount.
Lines 57-62 static inline void ref_put(struct ref *r, Link Here
57
57
58
#else
58
#else
59
#error "OS not supported"
59
#error "OS not supported"
60
#endif /* __GLIBC__, __FreeBSD__, __darwin__ */
60
#endif /* __GLIBC__, __linux__, __FreeBSD__, __darwin__ */
61
61
62
#endif /* TORSOCKS_REF_H */
62
#endif /* TORSOCKS_REF_H */
(-)a/src/lib/torsocks.h (-2 / +2 lines)
Lines 33-39 Link Here
33
#define TSOCKS_DECL(name, type, sig) \
33
#define TSOCKS_DECL(name, type, sig) \
34
	extern type tsocks_##name(sig);
34
	extern type tsocks_##name(sig);
35
35
36
#if (defined(__GLIBC__) || defined(__FreeBSD__) || defined(__darwin__) || defined(__NetBSD__))
36
#if (defined(__GLIBC__) || defined(__linux__) || defined(__FreeBSD__) || defined(__darwin__) || defined(__NetBSD__))
37
37
38
/* connect(2) */
38
/* connect(2) */
39
#include <sys/types.h>
39
#include <sys/types.h>
Lines 207-213 struct hostent **result, int *h_errnop Link Here
207
207
208
#else
208
#else
209
#error "OS not supported."
209
#error "OS not supported."
210
#endif /* __GLIBC__ , __FreeBSD__, __darwin__, __NetBSD__ */
210
#endif /* __GLIBC__, __linux__, __FreeBSD__, __darwin__, __NetBSD__ */
211
211
212
#if (defined(__linux__))
212
#if (defined(__linux__))
213
213

Return to bug 583730