From c41e8c840fd6faf802628036c7e5b2683d623c5d Mon Sep 17 00:00:00 2001 From: Mark Whitley Date: Wed, 12 Jul 2000 23:35:21 +0000 Subject: Changed bb_regcomp to xregcomp and #if 0'ed out destroy_cmd_strs in sed.c (maybe I'll remove it later). --- utility.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'utility.c') diff --git a/utility.c b/utility.c index 6d1e1d4bb..61f67618d 100644 --- a/utility.c +++ b/utility.c @@ -1722,18 +1722,15 @@ char *get_last_path_component(char *path) #endif #if defined BB_GREP || defined BB_SED -int bb_regcomp(regex_t *preg, const char *regex, int cflags) +void xregcomp(regex_t *preg, const char *regex, int cflags) { int ret; if ((ret = regcomp(preg, regex, cflags)) != 0) { int errmsgsz = regerror(ret, preg, NULL, 0); char *errmsg = xmalloc(errmsgsz); regerror(ret, preg, errmsg, errmsgsz); - errorMsg("bb_regcomp: %s\n", errmsg); - free(errmsg); - regfree(preg); + fatalError("bb_regcomp: %s\n", errmsg); } - return ret; } #endif -- cgit v1.2.3