GNU bug report logs - #24325
25.1; Crash - fd larger than FD_SETSIZE

Previous Next

Package: emacs;

Reported by: Robin Campbell Joy <emacs <at> robinjoy.net>

Date: Sun, 28 Aug 2016 17:12:02 UTC

Severity: normal

Found in version 25.1

Done: Paul Eggert <eggert <at> cs.ucla.edu>

Bug is archived. No further changes may be made.

Full log


Message #8 received at 24325 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Robin Campbell Joy <emacs <at> robinjoy.net>
Cc: 24325 <at> debbugs.gnu.org
Subject: Re: bug#24325: 25.1; Crash - fd larger than FD_SETSIZE
Date: Sun, 28 Aug 2016 20:53:24 +0300
> From: Robin Campbell Joy <emacs <at> robinjoy.net>
> Date: Sun, 28 Aug 2016 11:25:39 +0200
> 
> After a short time emacs is crashing while trying to communicate with an
> external process.
> 
> In the debugger I can see that the fd is larger than FD_SETSIZE. The fd
> is used in process.c:7168-7177 (setup_process_coding_system) to index
> into proc_decode_coding_system which is of size FD_SETSIZE and is
> crashing at process.c:5708 when dereferencing coding->id.

Do you really have several hundreds of subprocesses and/or network
connections active in that session?  If not, how come all the
descriptors below 1024 are in use?

I also don't understand how this:

> #0 0x00000000004942a4 in setup_coding_system (coding_system=4602512, coding=0xffffffffffffffff) at
> coding.c:5706
> eol_type = <optimized out>
          ^^^^^^^^^^^^
Can happen in a build that claims to use 'CFLAGS=-ggdb3 -O0'.  Did you
report the bug from the same binary that crashes?

I guess we will have to refuse to handle a process if its infd and
outfd are at or above FD_SETSIZE, like we do on MS-Windows?




This bug report was last modified 8 years and 306 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.