Sync usage with man page.
[netbsd-mini2440.git] / lib / libcompat / regexp / regerror.c
blob4650ffb1d97afca8966e561468f067359e1a79d2
1 #include <sys/cdefs.h>
2 #if defined(LIBC_SCCS) && !defined(lint)
3 __RCSID("$NetBSD: regerror.c,v 1.8 1999/09/20 04:48:04 lukem Exp $");
4 #endif /* LIBC_SCCS and not lint */
6 #include <assert.h>
7 #include <regexp.h>
8 #include <stdio.h>
10 /*ARGSUSED*/
11 void
12 __compat_regerror(s)
13 const char *s;
16 _DIAGASSERT(s != NULL);
18 #ifdef ERRAVAIL
19 error("regexp: %s", s);
20 #else
22 fprintf(stderr, "regexp(3): %s\n", s);
23 exit(1);
25 return; /* let std. egrep handle errors */
26 #endif
27 /* NOTREACHED */