Bug 120284 - x11-wm/windowmaker WPrefs crash on amd64
Summary: x11-wm/windowmaker WPrefs crash on amd64
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Doug Barton
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-02-05 07:40 UTC by Hiromi Kimura
Modified: 2009-03-06 10:26 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Hiromi Kimura 2008-02-05 07:40:01 UTC
After start the WindowMaker, double clicking the WPrefs icon makes core.

% cd /usr/local/GNUstep/Applications/WPrefs.app/
% gdb WPrefs
(gdb) r
  .....
Program received signal SIGSEGV, Segmentation fault.
0x00000008018ea57c in _XData32 () from /usr/local/lib/libX11.so.6
(gdb) bt
#0  0x00000008018ea57c in _XData32 () from /usr/local/lib/libX11.so.6
#1  0x00000008018c138f in XChangeProperty () from /usr/local/lib/libX11.so.6
#2  0x0000000000440ecc in WMSetWindowMiniwindowImage ()
#3  0x000000000040768a in Initialize ()
#4  0x00000000004066e2 in main ()

Fix: 

if (!image)
       return;

-    data = wmalloc((image->width * image->height + 2) * sizeof(CARD32));
+    data = wmalloc((image->width * image->height + 2) * sizeof(unsigned long));

     o= 0;
     data[o++] = image->width;--KZCWT7fPG2TSPCtTqVxAGnh3Rnum8AfXHbGZckSlg3vWCzN3
Content-Type: text/plain; name="file.diff"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment; filename="file.diff"

--- WINGs/wwindow.c.orig        2008-02-05 15:53:08.000000000 +0900
+++ WINGs/wwindow.c     2008-02-05 15:50:18.000000000 +0900
@@ -254,14 +254,14 @@
 setMiniwindow(WMWindow *win, RImage *image)
 {
     WMScreen *scr= win->view->screen;
-    CARD32 *data;
+    unsigned long *data;
     int x, y;
     int o;
How-To-Repeat: Install the packages:
 xorg-7.3_1.tbz
 windowmaker-0.92.0_3.tbz
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2008-02-05 07:40:06 UTC
Responsible Changed
From-To: freebsd-ports-bugs->dougb

Over to maintainer (via the GNATS Auto Assign Tool)
Comment 2 dfilter service freebsd_committer freebsd_triage 2008-12-31 10:01:41 UTC
dougb       2008-12-31 10:01:26 UTC

  FreeBSD ports repository

  Modified files:
    x11-wm/windowmaker/files patch-src_wmspec.c 
  Added files:
    x11-wm/windowmaker/files patch-WINGs_wwindow.c 
  Log:
  On amd64 clicking the WPrefs.app can cause a crash.
  
  Fix obtained partly from the PR and partly from the Debian RPM. The wmspec.c
  fix was confirmed in the latest version of windowmaker in their repo.
  
  PR:             ports/120284
  Submitted by:   Hiromi Kimura <hiromi@tac.tsukuba.ac.jp>
  
  Revision  Changes    Path
  1.1       +19 -0     ports/x11-wm/windowmaker/files/patch-WINGs_wwindow.c (new)
  1.2       +44 -10    ports/x11-wm/windowmaker/files/patch-src_wmspec.c
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 3 Doug Barton freebsd_committer freebsd_triage 2008-12-31 10:01:59 UTC
State Changed
From-To: open->feedback


I've committed a fix for this issue. Please confirm if it works for you.
Comment 4 Doug Barton freebsd_committer freebsd_triage 2009-03-06 10:25:17 UTC
State Changed
From-To: feedback->closed


Feedback timeout