Subject: Latest CVS cores out

From: Dan Espen <[email-masked]>
Date: Sat, 10 Apr 1999 08:16:18 -0400

This is as of last night:

(gdb) where
#0  0xef5d3d08 in strlen ()
#1  0x50504 in make_named_packet (len=0xefffe50c, event_type=2048,
    name=0x6520222a <Address 0x6520222a out of bounds>, num=3)
    at ../../version-2_3_1/fvwm/module.c:545
#2  0x506b8 in BroadcastName (event_type=2048, data1=8388620, data2=12583162,
    data3=1033696, name=0x6520222a <Address 0x6520222a out of bounds>)
    at ../../version-2_3_1/fvwm/module.c:590
#3  0x19358 in AddWindow (w=8388620, ReuseWin=0x0)
    at ../../version-2_3_1/fvwm/add_window.c:782
#4  0x30af0 in HandleMapRequestKeepRaised (KeepRaised=0, ReuseWin=0x0)
    at ../../version-2_3_1/fvwm/events.c:840
#5  0x37c78 in CaptureAllWindows () at ../../version-2_3_1/fvwm/fvwm.c:811
#6  0x2b76c in do_recapture (eventp=0x807e4, w=41, tmp_win=0x0, context=8,
    action=0xf8939 "", Module=0xefffeaac, fSingle=0)
    at ../../version-2_3_1/fvwm/builtins.c:3881
#7  0x2b820 in Recapture (eventp=0x807e4, w=41, tmp_win=0x0, context=8,
    action=0xf8939 "", Module=0xefffeaac)
    at ../../version-2_3_1/fvwm/builtins.c:3898
#8  0x34d9c in ExecuteFunction (Action=0xf8990 "Recapture", tmp_win=0x0,
    eventp=0x807e4, context=8, Module=-2, expand_cmd=EXPAND_COMMAND)
    at ../../version-2_3_1/fvwm/functions.c:526
#9  0x35d6c in ComplexFunction2 (eventp=0x807e4, w=0, tmp_win=0x0, context=8,
    action=0xf8a08 "DecorCustom\n", Module=0xefffecc4, desperate=0xefffec04)
    at ../../version-2_3_1/fvwm/functions.c:933
#10 0x34ddc in ExecuteFunction (Action=0xefffecf0 "DecorCustom\n",
    tmp_win=0x0, eventp=0x807e4, context=8, Module=-1,
    expand_cmd=EXPAND_COMMAND) at ../../version-2_3_1/fvwm/functions.c:533
#11 0x573c0 in ReadSubFunc (eventp=0x807e4, junk=41, tmp_win=0x0, context=8,
    action=0x8f17d ".fvwm2rc", Module=0xeffff2cc, piperead=0)
    at ../../version-2_3_1/fvwm/read.c:210
#12 0x574ac in ReadFile (eventp=0x807e4, w=41, tmp_win=0x0, context=8,
    action=0x8f17d ".fvwm2rc", Module=0xeffff2cc)
    at ../../version-2_3_1/fvwm/read.c:230
#13 0x34d9c in ExecuteFunction (Action=0x6c330 "Read .fvwm2rc", tmp_win=0x0,
    eventp=0x807e4, context=8, Module=-1, expand_cmd=EXPAND_COMMAND)
    at ../../version-2_3_1/fvwm/functions.c:526
#14 0x37360 in main (argc=1, argv=0xeffff79c)
    at ../../version-2_3_1/fvwm/fvwm.c:567

-- 
Dan Espen
444 Hoes Lane  Room RRC 1C-214             E-mail: [email-masked]
Piscataway, NJ 08854                       Phone: (732) 699-5570
--
Visit the official FVWM web page at <URL:http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm-workers" in the
body of a message to [email-masked].
To report problems, send mail to [email-masked]

---

From: Dan Espen <[email-masked]>
Date: Sat, 10 Apr 1999 09:34:25 -0400

>     data3=1033696, name=0x6520222a <Address 0x6520222a out of bounds>)
                                                ^^^^^^^^
And this "address" spells 'e "*'.
I've got another one that spells "Wind".

I also added a little debugging and got fvwm2 to start.

Plainly some string is overlaying the icon_name pointer.
The one above looks like part of a style command:

Style "*" xx
    ^^^^

the only "Wind" I could find in my configuration was "WindowFont".
If we don't get this one, this weekend, I'll try Purify at work.

---

From: Matthias Clasen <[email-masked]>
Date: Sun, 11 Apr 1999 00:48:22 +0200

> cc: [email-masked]
> Content-Type: text/plain; charset=US-ASCII
> Date: Sat, 10 Apr 1999 09:34:25 -0400
> From: Dan Espen <[email-masked]>
> Sender: [email-masked]
> Precedence: list
> X-Majordomo: 1.94.jlt7
> 

The problem with segfaults in the BroadcastName call from AddWindow 
seems to be that tmp_win->icon_name can go uninitialized
now that tmp_win is no longer calloc'ed, but safemalloc'ed.

The relevant initialization of icon_name is:

  if (XGetWMIconName (dpy, tmp_win->w, &text_prop))
    tmp_win->icon_name = (char *)text_prop.value;
  if(tmp_win->icon_name==(char *)NULL)
    tmp_win->icon_name = tmp_win->name;

This may fail to initialize icon_name if XGetWMIconName returns 0.

I have inserted an 

  else 
    tmp_win->icon_name = NULL;

to cure the problem. To prevent similar problems with other parts
of tmp_win, it may be safer to put a       

  memset(tmp_win, '\0', sizeof(FvwmWindow));

after the safemalloc.

Matthias

-- 
Matthias Clasen, 
Tel. 0761/203-5606
Email: [email-masked]
Mathematisches Institut, Albert-Ludwigs-Universitaet Freiburg
--
Visit the official FVWM web page at <URL:http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm-workers" in the
body of a message to [email-masked].
To report problems, send mail to [email-masked]

---

From: Dominik Vogt <[email-masked]>
Date: Sun, 11 Apr 1999 00:55:51 +0200

> If we don't get this one, this weekend, I'll try Purify at work.

Cant you run Purify and see if that provides more information?

Bye

Dominik ^_^

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

---

From: Dan Espen <[email-masked]>
Date: Sat, 10 Apr 1999 20:13:06 -0400

>   memset(tmp_win, '\0', sizeof(FvwmWindow));

I think  I've misled some of  you.  It isn't a  case  of icon_name not
being  initialised, I've now discovered that  the entire style section
of the window structure is overlayed.  Check it out:

(gdb) print tmp_win->style
$4 = {next = 0x20202044, name = 0x65636f72 <Address 0x65636f72 out of bounds>
  icon_name = 0x43757374 <Address 0x43757374 out of bounds>,
  mini_icon_name = 0x6f6d2022 <Address 0x6f6d2022 out of bounds>,
  decor_name = 0x4922204d <Address 0x4922204d out of bounds>,
  fore_color_name = 0x656e7553 <Address 0x656e7553 out of bounds>,
  back_color_name = 0x74796c65 <Address 0x74796c65 out of bounds>, flags = {
    common = {do_circulate_skip = 0, do_circulate_skip_icon = 0,
      do_grab_focus_when_created = 1, do_not_show_on_map = 0,
      do_start_iconic = 0, do_window_list_skip = 0, focus_mode = 0,
      has_mwm_border = 0, has_mwm_buttons = 0, has_mwm_override = 1,
      has_no_icon_title = 0, is_icon_sticky = 0, is_icon_suppressed = 0,
      is_lenient = 1, is_sticky = 0}, do_decorate_transient = 0,
    do_place_random = 0, do_place_smart = 1, do_start_lowered = 0,
    has_border_width = 0, has_color_back = 0, has_color_fore = 0,
    has_handle_width = 0, has_icon = 0, has_mini_icon = 0, has_mwm_decor = 1,
    has_mwm_functions = 0, has_no_border = 0, use_no_pposition = 0,
    has_no_title = 0, has_ol_decor = 0, use_start_on_desk = 0}, flag_mask = {
    common = {do_circulate_skip = 0, do_circulate_skip_icon = 1,
      do_grab_focus_when_created = 0, do_not_show_on_map = 0,
      do_start_iconic = 1, do_window_list_skip = 0, focus_mode = 1,
      has_mwm_border = 0, has_mwm_buttons = 1, has_mwm_override = 0,
      has_no_icon_title = 0, is_icon_sticky = 1, is_icon_suppressed = 1,
      is_lenient = 1, is_sticky = 0}, do_decorate_transient = 0,
    do_place_random = 1, do_place_smart = 0, do_start_lowered = 1,
    has_border_width = 0, has_color_back = 0, has_color_fore = 0,
    has_handle_width = 0, has_icon = 0, has_mini_icon = 1, has_mwm_decor = 1,
    has_mwm_functions = 0, has_no_border = 1, use_no_pposition = 1,
    has_no_title = 1, has_ol_decor = 1, use_start_on_desk = 0},
  on_buttons = 1883530604, off_buttons = 1635345764, border_width = 740315247
  layer = 1886744644, handle_width = 1701601657, start_desk = 540095792,
  start_page_x = 170598434, start_page_y = 1226973261, IconBoxes = 0x656e7553

So far, I haven't tracked down the source.  I think Purify will
catch it right away, but I have to go to work to use Purify.
(Well, I never tried running fvwm2 remotely.)

---

From: Dan Espen <[email-masked]>
Date: Mon, 12 Apr 1999 09:26:33 -0400

> If we don't get this one, this weekend, I'll try Purify at work.

Purify didn't help.  It hangs  before startup is complete.  It doesn't
find the problem before it hangs.

---

From: Dominik Vogt <[email-masked]>
Date: Wed, 14 Apr 1999 23:31:17 +0200

On Sat, Apr 10, 1999 at 08:13:06PM -0400, Dan Espen wrote:
>...

Dan, what's the status of this problem? Has it gone away? I think
I saw the same once, but recompiling solved the problem.

Bye

Dominik ^_^

---

From: Dan Espen <[email-masked]>
Date: Thu, 15 Apr 1999 08:27:51 -0400

> I saw the same once, but recompiling solved the problem.

I've been having this problem until this mornings CVS.  (My last
complete rebuild might have been 2 days ago).  Today everything
seems to be in order.

I also reported frames not being painted until the window got
focus.  This is also working now.