Subject: Re: FVWM: App crashes fvwm

From: Dan D Niles <[email-masked]>
Date: Mon, 29 Oct 2001 11:04:15 -0600

I got some more info.

 > #0  0x809354a in setup_window_placement (tmp_win=0x80f02b0, pstyle=0xbffff1c0)
 >     at add_window.c:578

The line it quits at is:

578         MergeCmdLineResources(
579           &db, table, 4, client_argv[0], &client_argc, client_argv, True);

(gdb) print db
$1 = 0x80f08b0
(gdb) print table
$2 = {{option = 0x80b3a25 "-workspacf", specifier = 0x80b3a1f "*junk", 
    argKind = XrmoptionSepArg, value = 0x0}, {option = 0x80b3a14 "-workspace", 
    specifier = 0x80b3a0e "*desk", argKind = XrmoptionSepArg, value = 0x0}, {
    option = 0x80b3a09 "-xrn", specifier = 0x0, argKind = XrmoptionResArg, 
    value = 0x0}, {option = 0x80b3a04 "-xrm", specifier = 0x0, 
    argKind = XrmoptionResArg, value = 0x0}}
(gdb) print client_argv[0]
Cannot access memory at address 0x0
(gdb) print client_argc
$3 = 0
(gdb) print client_argv
$4 = (char **) 0x0

client_argv is NULL, which is most likely what is causing the seg fault.
Is there some convention or RFC that implies that client_argv should
not have a NULL value?

Either way, it is a bug in FVWM (IMHO).  Fvwm should be able to handle
anything a client throws at it.

I'm sure I could hack something to get around this bug, but I'd rather
it was fixed in the "correct" manner. Does anyone have a fix or a
suggestion as to what the right way to fix this is?

Thanks,

Dan
--
Visit the official FVWM web page at <URL: http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to [email-masked].
To report problems, send mail to [email-masked].

---

From: Dominik Vogt <[email-masked]>
Date: Mon, 29 Oct 2001 18:34:24 +0100

> suggestion as to what the right way to fix this is?

It's already fixed in CVS.

Bye

Dominik ^_^  ^_^

-- 
Dominik Vogt, email: [email-masked]
LifeBits Aktiengesellschaft, Albrechtstr. 9, D-72072 Tuebingen
fon: ++49 (0) 7071/7965-0, fax: ++49 (0) 7071/7965-20
--
Visit the official FVWM web page at <URL: http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to [email-masked].
To report problems, send mail to [email-masked].