blob: 14dec0db00a75fd34e200cbdf9902202576d984e (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
--- sh.func.c.orig Sat Sep 19 01:09:11 1998
+++ sh.func.c Sat Sep 26 19:23:40 1998
@@ -1286,6 +1286,9 @@
struct command *c;
{
Char *vp, *lp;
+#ifdef __FreeBSD__
+ static int catclosed = 0;
+#endif
USE(c);
if (*++v == 0) {
@@ -1337,7 +1340,15 @@
# ifdef LC_MESSAGES
(void) setlocale(LC_MESSAGES, "");
# endif /* LC_MESSAGES */
+# ifdef __FreeBSD__
+ /* This code is to avoid bug. */
+ if (catclosed)
+ (void) catclose(catd);
+ else
+ catclosed = 1;
+# else
(void) catclose(catd);
+# endif /* __FreeBSD__ */
nlsinit();
# endif /* NLS_CATALOGS */
# ifdef LC_CTYPE
|