TrilbyWhite / alopex

A tabbed tiling window manager, with fur.
36 stars 4 forks source link

no-xinerama segfault #48

Open batpudding opened 10 years ago

batpudding commented 10 years ago

Might be my jenky compile, but alopex is taking me to Segfault City. It's a shame, because it looks really cool.

me@myhouse:~$ alopex Xlib: extension "XINERAMA" missing on display ":5". [X11 53:2] BadValue (integer parameter out of range for operation) Segmentation fault

me@myhouse:~$ strace alopex 2>&1 | tail -n 25 shmctl(2588679, IPC_RMID, 0) = 0 shmdt(0x7f64e768f000) = 0 poll([{fd=3, events=POLLIN|POLLOUT}], 1, 4294967295) = 1 ([{fd=3, revents=POLLOUT}]) writev(3, [{"b\1\4\0\7\0@\0", 8}, {"MIT-SHM", 7}, {"\0", 1}], 3) = 16 poll([{fd=3, events=POLLIN}], 1, 4294967295) = 1 ([{fd=3, revents=POLLIN}]) recvmsg(3, {msg_name(0)=NULL, msg_iov(1)=[{"\1\0\31\0\0\0\0\0\1\201A\200\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\1\0\0\0"..., 4096}], msg_controllen=0, msg_flags=0}, 0) = 32 recvmsg(3, 0x7fff8596a760, 0) = -1 EAGAIN (Resource temporarily unavailable) recvmsg(3, 0x7fff8596a760, 0) = -1 EAGAIN (Resource temporarily unavailable) shmget(IPC_PRIVATE, 4096, IPC_CREAT|0600) = 2621447 shmat(2621447, 0, 0) = ? poll([{fd=3, events=POLLIN|POLLOUT}], 1, 4294967295) = 1 ([{fd=3, revents=POLLOUT}]) writev(3, [{"\1\10\t\0\10\0@\0%\0\0\0\377\377\377\377\1\0\1\0\0\0\1\0\"\0\0\0\0\2\0\0"..., 40}, {NULL, 0}, {"", 0}], 3) = 40 poll([{fd=3, events=POLLIN}], 1, 4294967295) = 1 ([{fd=3, revents=POLLIN}]) recvmsg(3, {msg_name(0)=NULL, msg_iov(1)=[{"\1\0\33\0\0\0\0\0\1\0\0\0\0\0\0\0000\263g$\377\177\0\0\0\0\0\0\0\0\0\0"..., 4096}], msg_controllen=0, msg_flags=0}, 0) = 32 recvmsg(3, 0x7fff8596a7b0, 0) = -1 EAGAIN (Resource temporarily unavailable) recvmsg(3, 0x7fff8596a7b0, 0) = -1 EAGAIN (Resource temporarily unavailable) poll([{fd=3, events=POLLIN|POLLOUT}], 1, 4294967295) = 1 ([{fd=3, revents=POLLOUT}]) writev(3, [{"\201\1\4\0\t\0@\0\7\0(\0\0\377\377\377\31\0\v\0\10\0@\0\0\0\0\0\301\0\1\0"..., 72}, {NULL, 0}, {"", 0}], 3) = 72 poll([{fd=3, events=POLLIN}], 1, 4294967295) = 1 ([{fd=3, revents=POLLIN}]) recvmsg(3, {msg_name(0)=NULL, msg_iov(1)=[{"\0\2\35\0\301\0\0\0\0\0\31\2\0\0\0\0\200\265g$\377\177\0\0\0\0\0\0\0\0\0\0"..., 4096}], msg_controllen=0, msg_flags=0}, 0) = 64 recvmsg(3, 0x7fff8596a7b0, 0) = -1 EAGAIN (Resource temporarily unavailable) shmctl(2621447, IPC_RMID, 0) = 0 shmdt(0x7f64e768f000) = 0 --- SIGSEGV (Segmentation fault) @ 0 (0) --- +++ killed by SIGSEGV +++

TrilbyWhite commented 10 years ago

Can you tell me a bit about your setup? What hardware and what distro are you using?

I know dwm specifically checks if Xinerama is available - Alopex avoids the multiple mechanisms and just requires Xinerama as a dependency. Do you have xinerama installed? Is there any reason Xinerama would be incompatible with your hardware?

I suppose I could have a conditional compile block to completely excise that section for purely single-head systems. Mutli-monitor support is still very untested in v4 anyways as I haven't plugged in my second monitor. But in the absence of a second monitor, I've never run into trouble.

batpudding commented 10 years ago

Nah, I was just trying to test it out in an Xvnc. I stuck it on my real X and everything lit up, but the fault is the reason for the bug report.

If there's really no way to simply check for Xinerama, then it's probably not worth it, but an error message would sure be nicer than a fault.

Don't know if it's any use, but I poked around about detecting Xinerama without crashing and found this:

"Well, it turns out that the only Xinerma function The Bard's Tale calls is XineramaQueryScreens(). It returns 0 (and sets *number to 0) if Xinerama is not available, but the BardTale doesn't check that (it also doesn't call XFree() on the pointer)."

On Thu, Feb 27, 2014 at 3:45 AM, Jesse McClure notifications@github.comwrote:

Can you tell me a bit about your setup? What hardware and what distro are you using?

I know dwm specifically checks if Xinerama is available - Alopex avoids the multiple mechanisms and just requires Xinerama as a dependency. Do you have xinerama installed? Is there any reason Xinerama would be incompatible with your hardware?

Reply to this email directly or view it on GitHubhttps://github.com/TrilbyWhite/alopex/issues/48#issuecomment-36233955 .