From b0d31fa2631622d09730c85b5ce3e82b4886dd45 Mon Sep 17 00:00:00 2001 From: Pjotr Prins Date: Fri, 26 Jan 2018 10:57:14 +0000 Subject: Always check input data for strtok - unless -no-check is used --- src/debug.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/debug.cpp') diff --git a/src/debug.cpp b/src/debug.cpp index fd94f1e..45e57d7 100644 --- a/src/debug.cpp +++ b/src/debug.cpp @@ -143,7 +143,7 @@ gsl_vector *gsl_vector_safe_alloc(size_t n) { char *do_strtok_safe(char *tokenize, const char *delimiters, const char *__pretty_function, const char *__file, int __line) { auto token = strtok(tokenize,delimiters); - if (token == NULL && (is_debug_mode() || is_strict_mode())) + if (token == NULL && is_check_mode()) fail_at_msg(__file,__line,string("strtok failed in ") + __pretty_function); return token; } -- cgit v1.2.3