Red Hat axp-list: Linux on Alpha (1995-2022)
 help / color / mirror / Atom feed
* Re: X server crashes
@ 1998-06-30 18:58 DevGolfs18
  0 siblings, 0 replies; 6+ messages in thread
From: DevGolfs18 @ 1998-06-30 18:58 UTC (permalink / raw)
  To: axp-list

Please remove me from any and all of your mailing lists. Thank you very much.
Devin Rahn


^ permalink raw reply	[flat|nested] 6+ messages in thread
* X server crashes
@ 1998-06-29 19:06 Ken Raeburn
  1998-06-29 19:47 ` Matti Aarnio
  0 siblings, 1 reply; 6+ messages in thread
From: Ken Raeburn @ 1998-06-29 19:06 UTC (permalink / raw)
  To: axp-list


(Sorry if this has come up recently, I'm behind on my axp-list mail.)

My Matrox server has been crashing when I have too many connections.
I remember other people reporting this, but don't remember seeing a
solution, so I've been investigating, and here's one problem I've
found:

In os/WaitFor.c:

	    while (clientsReadable.fds_bits[i])
	    {
	        int client_priority, client_index;

		curclient = ffs (clientsReadable.fds_bits[i]) - 1;

clientsReadable is a standard fd_set, and it and ffs both come from
the installed header files.  However, fds_bits elements are type
"unsigned long int", and the ffs prototype is:

    extern int ffs  (int __i)  ;

So when clientsReadable.fds_bits[i] is 0x300000000, the function call
truncates the value to fit an "int", and ffs(0) is 0, so curclient
gets assigned -1, and things fall apart from there.

Note also that connection.c and io.c use ffs similarly, and perhaps
stuff in other directories too.

I'm not sure if it should be required that ffs be usable on elements
of an fd_set.  It really does only accept an int currently, it
truncates the value internally.

For now I'm probably just going to write a hack ffs64 so I can get
work done....

Ken


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~1998-06-30 18:59 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1998-06-30 18:58 X server crashes DevGolfs18
  -- strict thread matches above, loose matches on Subject: below --
1998-06-29 19:06 Ken Raeburn
1998-06-29 19:47 ` Matti Aarnio
1998-06-30  0:44   ` Andreas U. Trottmann
1998-06-30 14:10     ` Ken Raeburn
1998-06-30 16:44       ` Matti Aarnio

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox