Yesterday, I asked sun-managers :
>
>Dear Sun-Manager,
>
>I encounter problems with X11R6 (pl 2) xterm on Solaris 2.3 (kernel
>jumbo patch 101318-54) : Sometimes (1 out of 3), when xterm is started
>by an .xsession (ie, does not have a controlling terminal) xterm dies
>with the following message :
>
>xterm: Error 14, errno 22: Invalid argument
>
>I read something about that some days ago, but I haven't been able to
>retrieve it (specifically, I used gopher to access sun-managers archives)
>
>If I remember well, the problem was related to the way xterm deals
>with pseudo tty.
>
>Replacing X11R6 xterm by /usr/openwin/bin/xterm (101533-03 patch)
>gives the same results.
>
>I saw the fixes (03 to 05) of X11R6, but there is no code related to
>this problem.
I received only one answer (Casper Dik <casper@fwi.uva.nl>) who
suggest me to :
> A simple fix is finding the place where xterm opens /dev/tty and
> add a check for EINVAL.
That is what I have done, on X11R6 source of xterm. Here is the diff :
*** main.c.orig Wed Oct 5 11:36:18 1994
--- main.c Wed Oct 5 12:05:17 1994
***************
*** 1680,1686 ****
*/
if (tty < 0) {
if (tty_got_hung || errno == ENXIO || errno == EIO ||
! errno == ENOTTY) {
no_dev_tty = TRUE;
#ifdef TIOCSLTC
ltc = d_ltc;
--- 1680,1686 ----
*/
if (tty < 0) {
if (tty_got_hung || errno == ENXIO || errno == EIO ||
! errno == ENOTTY || errno == EINVAL) {
no_dev_tty = TRUE;
#ifdef TIOCSLTC
ltc = d_ltc;
------------------------------ END OF DIFF -C ------------------------------
-- ------------------------------------------------------------------------------ Claude Scarpelli Internet : claude@genethon.fr Centre de Recherche sur le Génome Humain
This archive was generated by hypermail 2.1.2 : Fri Sep 28 2001 - 23:09:11 CDT