ratpoison-devel
[Top][All Lists]
Advanced

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

Re: [RP] addhook crash (+ fix?)


From: Joshua Neuheisel
Subject: Re: [RP] addhook crash (+ fix?)
Date: Tue, 09 Aug 2005 08:12:13 -0400
User-agent: Mozilla Thunderbird 1.0.6-1.1.fc3 (X11/20050720)

FEJF wrote:
i just started using ratpoison to see if it's good for me ;). i tested some things and i encountered the problem that ratpoison (1.4.0-beta4 gentoo) always crashed when i tried to use the addhook command.
gdb showed that the actions.c file was the problem.

line 4602: free(dup);

if i remove it the crashes are gone. what i don't understand is what this dup-variable is good for. it's not even declared/used in the cmd_addhook function and i didn't find another place. so i wonder why the compiler doesn't throw an error and if it's any good?

The line compiles because 'dup' is a function defined in unistd.h. The free call is actually trying to free the dup function pointer, which will obviously cause problems for you.

The line should be removed from CVS also; it appears to be a copy-and-paste bug...

Joshua




reply via email to

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