aboutsummaryrefslogtreecommitdiff
path: root/src/common/compat.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/common/compat.h')
-rw-r--r--src/common/compat.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/common/compat.h b/src/common/compat.h
index 6b718c2f5..20c243e50 100644
--- a/src/common/compat.h
+++ b/src/common/compat.h
@@ -82,6 +82,10 @@ int tor_snprintf(char *str, size_t size, const char *format, ...)
CHECK_PRINTF(3,4);
int tor_vsnprintf(char *str, size_t size, const char *format, va_list args);
+#define TOR_ISSPACE(c) isspace((int)(unsigned char)(c))
+#define TOR_ISXDIGIT(c) isxdigit((int)(unsigned char)(c))
+#define TOR_ISDIGIT(c) isdigit((int)(unsigned char)(c))
+
/* ===== Time compatibility */
#if !defined(HAVE_GETTIMEOFDAY) && !defined(HAVE_STRUCT_TIMEVAL_TV_SEC)
struct timeval {