[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

lynx-dev Bug in inlocaldomain() on Solaris

From: Steve Snodgrass
Subject: lynx-dev Bug in inlocaldomain() on Solaris
Date: Mon, 11 May 1998 14:56:28 -0400


I tried installing Lynx 2.8 today on a Solaris 2.6 box but I had a problem
with anonymous users.  I wanted the anonymous users from the local domain to
be able to telnet out, while remote anonymous users shouldn't be able since
(since they presumably are able to telnet anyway).  Anyway, this wasn't
working correctly and I traced it down to a problem in the inlocaldomain()
function in LYUtils.c.

The variable mytty is set at line 2860 by doing a strrchr() with a '/'
character on the result of the ttyname() call, then it is incremented to get
past the '/' character.  Unfortunately, ptys on Solaris normally look like:


Thus, mytty ends up being set to "9" in this case.  The code then compares
this against the utmpx field ut_line, which is set to "pts/9".  This compare
fails and the loop ends up returning a bogus wtmp entry that has nothing to
do with the user in question.

On my system I did a quick patch of setting mytty to (ttyname(0) + 5) and
getting rid of the increment, but this probably isn't appropriate for all
systems.  I'll let the maintainers decide what to do with this one.

Steve Snodgrass * address@hidden * Crazed FORE Systems Unix Administrator
Quake/IRC ID: Pheran --- Geek Code: GCS/E s: a- C++ U++++$ L+ w PS+ b++ y+*
Game Worlds Network at for game news and reviews!
"I was thinking of the immortal words of Socrates who said 'I drank what?'."

reply via email to

[Prev in Thread] Current Thread [Next in Thread]