bugGNUstep Application Project - Bugs: bug #31466, GSPdf crashes while trying to open...

 
 

bug #31466: GSPdf crashes while trying to open a specific PDF file

Submitted by:  Sebastian Reitenbach <buzzdee>
Submitted on:  Tue 26 Oct 2010 01:41:11 PM UTC  
 
Category: NoneSeverity: 3 - Normal
Item Group: CrashStatus: Fixed
Privacy: PublicAssigned to: None
Open/Closed: Closed

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Tue 09 Nov 2010 05:58:51 PM UTC, comment #1:

This new backtrace now is from gnustep-core svn, and gspdf cvs checked out today, on the same OpenBSD system as mentioned below.

[Switching to process 4698, thread 0x89e8e000]
0x1c00f4ec in -[PSDocument initWithPsFileAtPath:] (self=0x848efc08, _cmd=0x3c006050, path=0x87c09308) at PSDocument.m:333
333 [psdmedia setWidth: doc->media[i].width];
Current language: auto; currently minimal
(gdb) bt
#0 0x1c00f4ec in -[PSDocument initWithPsFileAtPath:] (self=0x848efc08, _cmd=0x3c006050, path=0x87c09308) at PSDocument.m:333
#1 0x1c00a09b in -[GSPdfDocument readFromFile:ofType:] (self=0x80f49908, _cmd=0x2fce0048, fileName=0x8acdd1e8, docType=0x8022dce8) at GSPdfDocument.m:98
#2 0x0fdc8162 in -[NSDocument initWithContentsOfFile:ofType:] (self=0x80f49908, _cmd=0x2fce2458, fileName=0x8acdd1e8, fileType=0x8022dce8) at NSDocument.m:116
#3 0x0fdd0bd4 in -[NSDocumentController makeDocumentWithContentsOfFile:ofType:] (self=0x81f71b88, _cmd=0x2fce2498, fileName=0x8acdd1e8, type=0x8022dce8)
at NSDocumentController.m:390
#4 0x0fdd1704 in -[NSDocumentController openDocumentWithContentsOfFile:display:] (self=0x81f71b88, _cmd=0x3c0045f0, fileName=0x8acdd1e8, display=1 '\001')
at NSDocumentController.m:559
#5 0x1c008abe in -[GSPdf application:openFile:] (self=0x8aaee988, _cmd=0x2fd63ea0, app=0x8ace0c08, filename=0x8acdd1e8) at GSPdf.m:149
#6 0x0ff27c32 in -[GSServicesManager application:openFile:] (self=0x7c698b88, _cmd=0x2fcb64e8, theApp=0x8ace0c08, file=0x8acdd1e8) at GSServicesManager.m:583
#7 0x0fd5345e in -[NSApplication finishLaunching] (self=0x8ace0c08, _cmd=0x2fcb65d8) at NSApplication.m:1124
#8 0x0fd54c69 in -[NSApplication run] (self=0x8ace0c08, _cmd=0x2fcac000) at NSApplication.m:1517
#9 0x0fd3314f in NSApplicationMain (argc=3, argv=0xcfbc1c84) at Functions.m:89
#10 0x1c00fab4 in gnustep_base_user_main (argc=3, argv=0xcfbc1c84) at main.m:8
#11 0x0ee7c551 in main (argc=3, argv=0xcfbc1c84, env=0xcfbc1c94) at NSProcessInfo.m:933
#12 0x1c001847 in ___start ()
#13 0x1c0017c7 in _start ()
#14 0x00000000 in ?? ()
(gdb) frame 0
#0 0x1c00f4ec in -[PSDocument initWithPsFileAtPath:] (self=0x848efc08, _cmd=0x3c006050, path=0x87c09308) at PSDocument.m:333
333 [psdmedia setWidth: doc->media[i].width];
(gdb) list
328 psdmedia = [PSDocumentMedia documentMedia];
329
330 if (doc->pages[i].media != NULL)
331 {
332 [psdmedia setName: MAKESTRING (doc->pages[i].media->name)];
333 [psdmedia setWidth: doc->media[i].width];
334 [psdmedia setHeight: doc->media[i].height];
335 }
336
337 [psdpage setMedia: psdmedia];
(gdb) print i
$1 = 264
(gdb) print doc->media[i].width
Cannot access memory at address 0x7ecc2004
(gdb) print doc->media[0].width
$2 = 504
(gdb) print doc->media[1].width
$3 = 120
(gdb) print doc->media[2].width
$4 = 36
(gdb) print doc->media[3].width
$5 = -2069559768
(gdb) print doc->media[4].width
$6 = 0
(gdb) print doc->media[i].height
Cannot access memory at address 0x7ecc2008
(gdb) print doc->pages[i].media->name
$7 = 0x7f981a30 "y661.5x504"

I guess its checking the width and height of all pages?
Just to make sure, I ran it a second time from within gdb, and it crashed with i=169, so its not always the same page.
print doc->media[168].width was working, but not doc->media[i].width.

Sebastian Reitenbach <buzzdee>
Project Member
Tue 26 Oct 2010 01:41:11 PM UTC, original submission:

Sometimes the PDF is shown, sometimes GSPdf crashes. When it crashes, the crasher always happen at the same location.
So the crasher is a kind of randomly happen.

I'm on OpenBSD i386.
gnustep-back-0.18.0p3 GNUstep gui backend
gnustep-base-1.20.1p0 GNUstep base library
gnustep-gui-0.18.0p1 GNUstep gui library
gnustep-make-2.4.0p1 GNUstep makefile package
gspdf-0.3 PDF, PS and EPS viewer for gnustep

I can send the PDF in question if necessary.

Loaded symbols for /usr/X11R6/lib/libXcursor.so.4.0
#0 0x1c00d379 in -[PSDocument initWithPsFileAtPath:] (self=0x8984ef08, _cmd=0x3c005808,
path=0x8bed4608) at PSDocument.m:333
333 [psdmedia setWidth: doc->media[i].width];
(gdb) bt
#0 0x1c00d379 in -[PSDocument initWithPsFileAtPath:] (self=0x8984ef08, _cmd=0x3c005808,
path=0x8bed4608) at PSDocument.m:333
#1 0x1c00a9fc in -[GSPdfDocument initForPath:] (self=0x89abaf88, _cmd=0x3c003bb8, apath=0x8984b888)
at GSPdfDocument.m:178
#2 0x1c006fac in -[GSPdf openDocumentForPath:] (self=0x85ed0108, _cmd=0x3c003b88, path=0x8984b888)
at GSPdf.m:166
#3 0x1c006f2a in -[GSPdf openFile:] (self=0x85ed0108, _cmd=0x7d7820e8, sender=0x83bd3d08)
at GSPdf.m:197
#4 0x07449962 in nsanimation_progressMarkSorter () from /usr/local/lib/libgnustep-gui.so.0.18
#5 0x07507e51 in GSBindingInvokeAction () from /usr/local/lib/libgnustep-gui.so.0.18
#6 0x07511b5f in GSBindingInvokeAction () from /usr/local/lib/libgnustep-gui.so.0.18
#7 0x0750f72f in GSBindingInvokeAction () from /usr/local/lib/libgnustep-gui.so.0.18
#8 0x075cff98 in GSViewAcceptsDrag () from /usr/local/lib/libgnustep-gui.so.0.18
#9 0x0744d242 in GSGuiBundle () from /usr/local/lib/libgnustep-gui.so.0.18
#10 0x0744f3a4 in gsapp_user_bundles () from /usr/local/lib/libgnustep-gui.so.0.18
#11 0x07430eb3 in NSApplicationMain () from /usr/local/lib/libgnustep-gui.so.0.18
#12 0x1c00d654 in gnustep_base_user_main (argc=1, argv=0xcfbf27d8) at main.m:8
#13 0x03a28d4e in main () from /usr/local/lib/libgnustep-base.so.3.1
#14 0x00000001 in ?? ()
#15 0xcfbf27d8 in ?? ()
#16 0xcfbf27e0 in ?? ()
#17 0x3c000033 in ?? ()
#18 0x3c00b860 in environ ()
---Type <return> to continue, or q <return> to quit---
#19 0x00000001 in ?? ()
#20 0xcfbf279c in ?? ()
#21 0x3c00a718 in ?? ()
#22 0x3c00b95f in __progname_storage ()
#23 0x3c00b860 in environ ()
#24 0xcfbf27b4 in ?? ()
#25 0x1c001807 in ___start ()
#26 0x1c001807 in ___start ()
#27 0x1c001787 in _start ()
#28 0x00000000 in ?? ()
Current language: auto; currently minimal
(gdb) frame 0
#0 0x1c00d379 in -[PSDocument initWithPsFileAtPath:] (self=0x8984ef08, _cmd=0x3c005808,
path=0x8bed4608) at PSDocument.m:333
333 [psdmedia setWidth: doc->media[i].width];
(gdb) list
328 psdmedia = [PSDocumentMedia documentMedia];
329
330 if (doc->pages[i].media != NULL)
331 {
332 [psdmedia setName: MAKESTRING (doc->pages[i].media->name)];
333 [psdmedia setWidth: doc->media[i].width];
334 [psdmedia setHeight: doc->media[i].height];
335 }
336
337 [psdpage setMedia: psdmedia];
(gdb)

Sebastian Reitenbach <buzzdee>
Project Member

 

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

Attach File(s):
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by rmottola (Updated the item)
  • -unavailable- added by buzzdee (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 3 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Wed 25 Jan 2012 05:45:29 PM UTCbuzzdeeStatusReady For Test=>Fixed
      Open/ClosedOpen=>Closed
    Fri 12 Nov 2010 11:05:39 AM UTCrmottolaStatusNone=>Ready For Test

    Back to the top


    Powered by Savane 3.1-cleanup1