Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 17 Oct 1995 07:23:40 EST
From:      "Kaleb S. KEITHLEY" <kaleb@x.org>
To:        Terry Lambert <terry@lambert.org>
Cc:        hackers@freefall.FreeBSD.org
Subject:   Re: A couple problems in FreeBSD 2.1.0-950922-SNAP 
Message-ID:  <199510171123.HAA08614@exalt.x.org>
In-Reply-To: Your message of Mon, 16 Oct 1995 19:04:08 EST. <199510170204.TAA26154@phaeton.artisoft.com> 

next in thread | previous in thread | raw e-mail | index | archive | help

> > I have the following by default in my environment :
> > 
> > LANG=fr_FR.ISO_8859-1
> > LC_CTYPE=iso_8859_1
> > 
> > As soon  as I switch LC_CTYPE  to fr_FR.ISO_8859-1, all xterms started from
> > this terminal  will  dump core  (well,  they won't because  xterm is setuid
> > root), each time. The signal is SEGV. 
> 
> Your xterm is improperly pretending to be internationalized.  It's
> pretending because there is bogus code in crt0.o that causes it to
> call setlocale() when XPG/3 and XPG/4 both say it shouldn't.
> 
> Either don't try to run in an international environment... or use
> an xterm clone from contrib instead of xterm that really has been
> internationalized.

The xterm in question has been internationalized. However there appears
to be an unanticipated side effect caused by both crt0.o and Xt calling
setlocale, or it might be the LC_CTYPE=iso_8859_1, which *is* bogus for 
FreeBSD. If the user wants to set LC_CTYPE, it should be to a valid
locale name for the system. 

(The LC_CTYPE=iso_8859_1 is a SunOS thing that was apparently copied 
from an example in a FAQ about how to get 8859-1 on SunOS.)

Xedit in the R6 contrib has also been internationalized. Since it does 
not dump core on FreeBSD, with or without ENABLE_STARTUP_LOCALE, with 
or without the bogus LC_CTYPE, and the stack trace showed that it dumped
core in xterm code, the problem may be that xterm assumes the startup
locale will be C.

--

Kaleb



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199510171123.HAA08614>