From: Bill Erickson Date: Mon, 23 Nov 2015 16:25:12 +0000 (-0500) Subject: LP#1468422 free barcode regex X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=4849f1cef3254f41e60fa64a1263396cbcb7834a;p=working%2FEvergreen.git LP#1468422 free barcode regex Signed-off-by: Bill Erickson --- diff --git a/Open-ILS/src/c-apps/oils_auth.c b/Open-ILS/src/c-apps/oils_auth.c index 63c200a229..b9998b52ff 100644 --- a/Open-ILS/src/c-apps/oils_auth.c +++ b/Open-ILS/src/c-apps/oils_auth.c @@ -349,6 +349,7 @@ static int oilsAuthIdentIsBarcode(const char* identifier) { if (compiled == NULL) { osrfLogError(OSRF_LOG_MARK, "Could not compile '%s': %s", bc_regex, err_str); + free(bc_regex); pcre_free(compiled); return 0; } @@ -358,6 +359,7 @@ static int oilsAuthIdentIsBarcode(const char* identifier) { if(err_str != NULL) { osrfLogError(OSRF_LOG_MARK, "Could not study regex '%s': %s", bc_regex, err_str); + free(bc_regex); pcre_free(compiled); return 0; } @@ -365,6 +367,7 @@ static int oilsAuthIdentIsBarcode(const char* identifier) { match_ret = pcre_exec( compiled, extra, identifier, strlen(identifier), 0, 0, NULL, 0); + free(bc_regex); pcre_free(compiled); if (extra) pcre_free(extra);