projects
/
oweals
/
busybox.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
less: total cleanup and bugfix.
[oweals/busybox.git]
/
libbb
/
xregcomp.c
diff --git
a/libbb/xregcomp.c
b/libbb/xregcomp.c
index 4bcb9aedf548301086dda4c90492a5e6aaca16cf..6e9a29f49c85c7350394e5f1ff2823d89eab7f30 100644
(file)
--- a/
libbb/xregcomp.c
+++ b/
libbb/xregcomp.c
@@
-8,16
+8,13
@@
* Licensed under GPLv2 or later, see file LICENSE in this tarball for details.
*/
* Licensed under GPLv2 or later, see file LICENSE in this tarball for details.
*/
-#include <stdio.h>
#include "libbb.h"
#include "xregex.h"
#include "libbb.h"
#include "xregex.h"
-
-
void xregcomp(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 ret
= regcomp(preg, regex, cflags)
;
+ if (
ret
) {
int errmsgsz = regerror(ret, preg, NULL, 0);
char *errmsg = xmalloc(errmsgsz);
regerror(ret, preg, errmsg, errmsgsz);
int errmsgsz = regerror(ret, preg, NULL, 0);
char *errmsg = xmalloc(errmsgsz);
regerror(ret, preg, errmsg, errmsgsz);