From 03be6eb89a1d05cf39e9278e0b0813ead3787519 Mon Sep 17 00:00:00 2001 From: Petr Machata Date: Fri, 9 Nov 2012 16:42:36 +0100 Subject: In globcomp, use REG_NOERROR instead of literal 0 Hopefully this will make it clearer that the protocol is different than everywhere else in ltrace, where <0 is error condition. --- glob.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'glob.c') diff --git a/glob.c b/glob.c index 9b7123e..9c0a597 100644 --- a/glob.c +++ b/glob.c @@ -179,7 +179,7 @@ glob_to_regex(const char *glob, char **retp) goto fail; } *retp = buf; - return 0; + return REG_NOERROR; } int @@ -187,7 +187,7 @@ globcomp(regex_t *preg, const char *glob, int cflags) { char *regex; int status = glob_to_regex(glob, ®ex); - if (status != 0) + if (status != REG_NOERROR) return status; status = regcomp(preg, regex, cflags); free(regex); -- cgit v1.2.3