bugGNUstep - Bugs: bug #25040, Ink from examples crashing on...

Group
 
 

bug #25040: Ink from examples crashing on openbsd sparc64

Submitter:  Sebastian Reitenbach <buzzdee>
Submitted:  Mon 08 Dec 2008 08:54:54 PM UTC
   
 
Category:  Base/Foundation Severity:  3 - Normal
Item Group:  Bug Status:  Duplicate
Privacy:  Public Assigned to:  None
Open/Closed:  Closed
* Mandatory Fields

Add a New Comment Rich Markup
   

Jump to the original submission

Sun 04 Jan 2009 09:59:15 PM UTC, comment #7: 

Apparently fixed.

Richard Frith-Macdonald <CaS>
Group Member
Mon 15 Dec 2008 07:41:02 PM UTC, comment #6: 

Most likely this is just another duplicate of #25033, expressing itself a bit differently.

Fred Kiefer <FredKiefer>
Group Member
Tue 09 Dec 2008 10:41:04 AM UTC, comment #5: 


> 0x8 doesn't look like a pointer, it seems to be a value
> and 0 is something of an unlikely length.


I agree ... the length comes from the ffi stuff so it does suggest a problem in libffi.
I also wonder how/why the crash occurred though ... with a length of zero the memcpy should have done nothing, so there should be no reason for it to segfault ... so perhaps the data in the stacktrace is corrupt and we aren't seeing the values that were really used.

Richard Frith-Macdonald <CaS>
Group Member
Tue 09 Dec 2008 08:38:42 AM UTC, comment #4: 

Sorry, for not expressing myself clear enough. I was refering to the list of platforms supported by libffi:

http://sources.redhat.com/libffi/

I don't think that we have anybody in GNUstep that supports specific platforms. It is more that we have people with different experiences.

And for the issue at hand I have no idea how to find out whether sparc64 passes structures by copy or not. It is just that the memcpy arguments look totally wrong to me. 0x8 doesn't look like a pointer, it seems to be a value and 0 is something of an unlikely length.

Fred Kiefer <FredKiefer>
Group Member
Tue 09 Dec 2008 08:30:11 AM UTC, comment #3: 


> openbsd is not on the list of the supported platforms, but freebsd is


I'm wondering ... where is this list, and who is it that supports freebsd/sparc64?

It seems to me that, where we have platform specific issues, we should flag them up to whoever supports that platform rather than just leaving them on the general bugs list.

Richard Frith-Macdonald <CaS>
Group Member
Tue 09 Dec 2008 08:13:20 AM UTC, comment #2: 

This definitily is no application bug, as the problem doesn't happen in Ink itself. It is either caused by base, where your sparc64 may end up in the wrong case of MFRAME_STRUCT_BYREF or by a problem in the ffi library for your platform. (openbsd is not on the list of the supported platforms, but freebsd is)

As soon as we can rule out a problem in base, we should switch this bug report to libraries.

Fred Kiefer <FredKiefer>
Group Member
Mon 08 Dec 2008 08:56:46 PM UTC, comment #1: 

same version of Ink works well on openbsd 4.4 i386.

Sebastian Reitenbach <buzzdee>
Group Member
Mon 08 Dec 2008 08:54:54 PM UTC, original submission:  

When entering the first letter into Ink, it crashes, also after opening a new document, and trying to Insert file... from the Document menu, Ink crashes too.

Program received signal SIGSEGV, Segmentation fault.
0x0000000041a85ea4 in memcpy (dst0=0x4213ca88, src0=0x8, length=0) at /usr/src/lib/libc/string/bcopy.c:115
115     /usr/src/lib/libc/string/bcopy.c: No such file or directory.
        in /usr/src/lib/libc/string/bcopy.c
(gdb) bt
#0  0x0000000041a85ea4 in memcpy (dst0=0x4213ca88, src0=0x8, length=0) at /usr/src/lib/libc/string/bcopy.c:115
#1  0x000000004c4d81ec in -[GSFFIInvocation initWithCallback:returnp:values:frame:signature:] (self=0x4069a490,
    _cmd=0x4c8a0bc8, cif=0x4213ca00, retp=0xffffffffffff46e0, vals=0xffffffffffff45f0, frame=0x4213ca00, aSignature=0x4211d2d0)
    at GSFFIInvocation.m:283
#2  0x000000004c4d8a5c in GSFFIInvocationCallback (cif=0x4213ca00, retp=0xffffffffffff46e0, args=0xffffffffffff45f0,
    user=0x4213ca00) at GSFFIInvocation.m:530
#3  0x0000000042a5b19c in ffi_closure_sparc_inner_v9 (closure=0x45eae000, rvalue=0xffffffffffff46e0, gpr=0xffffffffffff4800,
    fpr=0xffffffffffff4700) at src/sparc/ffi.c:606
#4  0x0000000042a5b518 in ffi_closure_v9 () from /usr/local/lib/libffi.so.0.0
#5  0x0000000041221ca4 in -[NSTextView shouldChangeTextInRange:replacementString:] (self=0x447d7010, _cmd=0x415ab778,
    affectedCharRange={location = 0, length = 0}, replacementString=0x4211c410) at NSTextView.m:2502
#6  0x00000000412203ac in -[NSTextView insertText:] (self=0x447d7010, _cmd=0x4154b768, insertString=0x4211c410)
    at NSTextView.m:2002
#7  0x0000000041100f84 in -[NSInputManager insertText:] (self=0x487a8e90, _cmd=0x4154b768, aString=0x4211c410)
    at NSInputManager.m:785
#8  0x0000000041100724 in -[NSInputManager handleKeyboardEvents:client:] (self=0x487a8e90, _cmd=0x4154b478,
    eventArray=0x4069a010, client=0x447d7010) at NSInputManager.m:675
#9  0x0000000041155394 in -[NSResponder interpretKeyEvents:] (self=0x447d7010, _cmd=0x415ac308, eventArray=0x4211c450)
    at NSResponder.m:144
#10 0x000000004122a29c in -[NSTextView(leftovers) keyDown:] (self=0x447d7010, _cmd=0x41591be0, theEvent=0x4069a010)
    at NSTextView.m:4868
#11 0x00000000411daef8 in -[NSWindow sendEvent:] (self=0x451b8210, _cmd=0x415149b0, theEvent=0x4069a010) at NSWindow.m:3667
#12 0x000000004105bcb4 in -[NSApplication sendEvent:] (self=0x487a6810, _cmd=0x41514830, theEvent=0x4069a010)
    at NSApplication.m:1884
#13 0x000000004105a6b8 in -[NSApplication run] (self=0x487a6810, _cmd=0x419d56d0) at NSApplication.m:1386
#14 0x000000004103e61c in NSApplicationMain (argc=1095802952, argv=0xffffffffffff51e8) at Functions.m:74
#15 0x0000000000101138 in ___start ()
#16 0x000000004ef02f24 in _dl_start () from /usr/libexec/ld.so
#17 0x000000004ef02f24 in _dl_start () from /usr/libexec/ld.so
Previous frame identical to this frame (corrupt stack?)

$ openapp --debug Ink
GNU gdb 6.3
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "sparc64-unknown-openbsd4.3"...
(gdb) r
Starting program: /usr/local/libexec/GNUstep/Ink.app/Ink
2008-12-08 21:21:56.660 Ink[14872] Ignore bottom offset change from 33 to 9
2008-12-08 21:21:56.664 Ink[14872] Reparent was with offset 0 24
2008-12-08 21:21:56.664 Ink[14872] Parent border,width,height 1,550,582
2008-12-08 21:22:00.159 Ink[14872] Ignore bottom offset change from 33 to 9
2008-12-08 21:22:00.159 Ink[14872] Reparent was with offset 0 24
2008-12-08 21:22:00.160 Ink[14872] Parent border,width,height 1,384,490

Program received signal SIGSEGV, Segmentation fault.
0x00000000460fdea4 in memcpy (dst0=0x474d2e88, src0=0x8, length=0) at /usr/src/lib/libc/string/bcopy.c:115
115     /usr/src/lib/libc/string/bcopy.c: No such file or directory.
        in /usr/src/lib/libc/string/bcopy.c
(gdb) bt
#0  0x00000000460fdea4 in memcpy (dst0=0x474d2e88, src0=0x8, length=0) at /usr/src/lib/libc/string/bcopy.c:115
#1  0x00000000447b41ec in -[GSFFIInvocation initWithCallback:returnp:values:frame:signature:] (self=0x41e49610,
    _cmd=0x44b7cbc8, cif=0x474d2e00, retp=0xfffffffffffe8830, vals=0xfffffffffffe8740, frame=0x474d2e00, aSignature=0x583897d0)
    at GSFFIInvocation.m:283
#2  0x00000000447b4a5c in GSFFIInvocationCallback (cif=0x474d2e00, retp=0xfffffffffffe8830, args=0xfffffffffffe8740,
    user=0x474d2e00) at GSFFIInvocation.m:530
#3  0x000000005051b19c in ffi_closure_sparc_inner_v9 (closure=0x4d900000, rvalue=0xfffffffffffe8830, gpr=0xfffffffffffe8950,
    fpr=0xfffffffffffe8850) at src/sparc/ffi.c:606
#4  0x000000005051b518 in ffi_closure_v9 () from /usr/local/lib/libffi.so.0.0
#5  0x0000000049ff1ca4 in -[NSTextView shouldChangeTextInRange:replacementString:] (self=0x4ebb8e10, _cmd=0x4a37b778,
    affectedCharRange={location = 0, length = 0}, replacementString=0x45643a90) at NSTextView.m:2502
#6  0x0000000049ff03ac in -[NSTextView insertText:] (self=0x4ebb8e10, _cmd=0x307538, insertString=0x58389450)
    at NSTextView.m:2002
#7  0x0000000000102884 in -[Document insertFile:] (self=0x47492710, _cmd=0x0, sender=0x0) at Document.m:320
#8  0x000000005051b42c in ffi_call_v9 () from /usr/local/lib/libffi.so.0.0
#9  0x000000005051ad8c in ffi_call (cif=0x431d7100, fn=0x1025c0 <-[Document insertFile:]>, rvalue=0x431d7180,
    avalue=0x431d7150) at src/sparc/ffi.c:405
#10 0x00000000447b445c in -[GSFFIInvocation invokeWithTarget:] (self=0x4194a610, _cmd=0x0, anObject=0x47492710)
    at GSFFIInvocation.m:383
#11 0x0000000049e2c5bc in -[NSApplication sendAction:to:from:] (self=0x1, _cmd=0x4a3232b0, aSelector=0x43d28460,
    aTarget=0x47492710, sender=0x43d3ef10) at NSApplication.m:2003
#12 0x0000000049eebd10 in -[NSMenu performActionForItemAtIndex:] (self=0x43d41610, _cmd=0x4a325360, index=1137869920)
    at NSMenu.m:1139
#13 0x0000000049ef391c in -[NSMenuView trackWithEvent:] (self=0x41272c10, _cmd=0x2, event=0x4194a290) at NSMenuView.m:1606
#14 0x0000000049ef44fc in -[NSMenuView mouseDown:] (self=0x41272c10, _cmd=0x4a361d60, theEvent=0x4194a090) at NSMenuView.m:1651
#15 0x0000000049faaa30 in -[NSWindow sendEvent:] (self=0x41272410, _cmd=0x4a2e49b0, theEvent=0x4194a090) at NSWindow.m:3561
#16 0x0000000049e2bcb4 in -[NSApplication sendEvent:] (self=0x40528710, _cmd=0x4a2e4830, theEvent=0x4194a090)
    at NSApplication.m:1884
#17 0x0000000049e2a6b8 in -[NSApplication run] (self=0x40528710, _cmd=0x4a7a56d0) at NSApplication.m:1386
#18 0x0000000049e0e61c in NSApplicationMain (argc=1244504136, argv=0xfffffffffffe97a8) at Functions.m:74
#19 0x0000000000101138 in ___start ()
#20 0x000000004da02f24 in _dl_start () from /usr/libexec/ld.so
#21 0x000000004da02f24 in _dl_start () from /usr/libexec/ld.so
Previous frame identical to this frame (corrupt stack?)

OpenBSD 4.3, sparc64
# gcc -v
Reading specs from /usr/lib/gcc-lib/sparc64-unknown-openbsd4.3/3.3.5/specs
Configured with:
Thread model: single
gcc version 3.3.5 (propolice)
gnustep-make-2.0.6
gnustep-base-1.16.5 linked against libffi-3.0.7
gnustep-back-0.14.0
gnustep-gui-0.14.0
gnustep-examples-1.2.0p3

Sebastian Reitenbach <buzzdee>
Group Member

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Digest:
   bug dependencies.

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by CaS (Posted a comment)
  • -email is unavailable- added by FredKiefer (Posted a comment)
  • -email is unavailable- added by buzzdee (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    Follow 4 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2009-01-04 CaS Open/ClosedOpen Closed
    2008-12-15 FredKiefer StatusNone Duplicate
        Dependencies- Depends on bugs #25033
    2008-12-09 FredKiefer CategoryApplication Base/Foundation

    Back to the top

    Powered by Savane 3.13-d3ae.
    Corresponding source code