Fix cross compilation (e.g. on Darwin). Following changes to make.tmpl,
[AROS.git] / arch / all-pc / boot / grub2-aros / grub-core / gnulib-no-abort.diff
blob8377338f7d26c7922d7a2da0fa16a3cb9018a0bb
1 === modified file 'grub-core/gnulib/regcomp.c'
2 --- grub-core/gnulib/regcomp.c 2010-09-20 10:35:33 +0000
3 +++ grub-core/gnulib/regcomp.c 2012-03-10 11:31:42 +0000
4 @@ -549,13 +549,9 @@ regerror (int errcode, const regex_t *_R
5 if (BE (errcode < 0
6 || errcode >= (int) (sizeof (__re_error_msgid_idx)
7 / sizeof (__re_error_msgid_idx[0])), 0))
8 - /* Only error codes returned by the rest of the code should be passed
9 - to this routine. If we are given anything else, or if other regex
10 - code generates an invalid error code, then the program has a bug.
11 - Dump core so we can fix it. */
12 - abort ();
14 - msg = gettext (__re_error_msgid + __re_error_msgid_idx[errcode]);
15 + msg = gettext ("unknown regexp error");
16 + else
17 + msg = gettext (__re_error_msgid + __re_error_msgid_idx[errcode]);
19 msg_size = strlen (msg) + 1; /* Includes the null. */
21 @@ -1119,7 +1119,7 @@
23 break;
24 default:
25 - abort ();
26 + break;
29 if (mb_chars || has_period)