The included mc package in limbo crashes the instant i try to edit a file with it to reproduce: #> mcedit some_existing_file.txt (Segfault or freeze using 100% cpu) I tried to install rh 7.3's version of mc, and it had the same result (even temporary downgraded slang to try that out). But all to no avail. Then i remebered i had 'cooled' laying around, a version of / riped from mcedit (which was riped from cooledit) with some minor modifications. However its a lot older and has simpler code. (so easier to debug). It can be found at: http://cooled.sourceforge.net/ I compiled it with -O -ggdb, and gdb'd it. It had exactly the same crash as mcedit did. (good, simpler compile / code base for me to test on!) gdb's 'bt' told me it crashed on key.c, line 761, which in source is: #ifdef HAVE_LIBGPM if (gpm_flag) { FD_SET(gpm_fd, &select_set); } #endif After i #define HAVE_LIBGPM 0 in config.h and recompile, it cooled works as expected. (though without any mouse functionality, cooled 0.5 didnt have xterm mouse handling yet). So it seems something in the mouse handling / interface of gpm has broken mcedit / cooled.. So i verified that the same is true for the supplied mc package. I edited mc-4.5.55/src/key.c line around 722 and commented out the HAVE_LIBGPM part, and recompiled the package. After this mcedit works again, the mouse is functional in xterm's (uses a different library / call), and the mouse is non functional on the console (as expected). So it is definatly that call to the FD_SET(gpm_fd, &select_set); in key.c:722 that kills mcedit on startup. (I'd love to dig deeper and realy fix it, but my C coding days are 4 years behind me, so its all a bit rusty) I hope it goes a long way in helping you fix the problem though
Since mc hasn't changed since 7.3, I'll tentatively blame gpm and move it over there.
Additional comment: While tracing through the editor, i noticed that gpm_fd has a value of -2, is that vallid for a file handle?? gpm_fd is gotton from mcedit's mouse.h, which defines it as a externel int, gotton from gpm.h Maybe thats a lead?
Fixed in current release (4.6.x) in either gpm or mc.. closing bug