App Crashing, help!

Discussion in 'iOS Development' started by Rockstarou812, May 18, 2009.

  1. Rockstarou812

    Rockstarou812 New Member

    Joined:
    Jan 17, 2009
    Messages:
    43
    Likes Received:
    0
    Ok, well my app keeps crashing, first I thought it was this random thing, because it would work perfectly, then it would randomly crash.

    But I think I found why it did so, while the app was open I left my iPod, and it turned off automatically, hours later when I unlocked it and tried to scroll through the UITableView, it froze. Then after about 15 sec closed and went to the home screen.

    Thankfully I got this into the debugger and this is what shows:

    Code:
    [Session started at 2009-05-17 15:27:13 -0400.]
    2009-05-17 15:29:22.886 PaperTopia[6842:20b] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** -[NSURL initWithString:relativeToURL:]: nil string parameter'
    
    [Session started at 2009-05-17 15:29:23 -0400.]
    2009-05-17 15:29:22.887 PaperTopia[6842:20b] Stack: (
        2507063467,
        2501455419,
        2507062923,
        2507062986,
        2459634675,
        2459634290,
        2459634193,
        11758,
        816410155,
        816411183,
        816487009,
        816434651,
        836031104,
        836030896,
        836029242,
        836028507,
        2506557762,
        2506564516,
        2506566776,
        827657132,
        827657329,
        816140195,
        816185735,
        9972,
        9826
    )
    Loading program into debugger…
    GNU gdb 6.3.50-20050815 (Apple version gdb-962) (Sat Jul 26 08:14:40 UTC 2008)
    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 "i386-apple-darwin".warning: Unable to read symbols for "/System/Library/Frameworks/UIKit.framework/UIKit" (file not found).
    warning: Unable to read symbols from "UIKit" (not yet mapped into memory).
    warning: Unable to read symbols for "/System/Library/Frameworks/CoreGraphics.framework/CoreGraphics" (file not found).
    warning: Unable to read symbols from "CoreGraphics" (not yet mapped into memory).
    Program loaded.
    sharedlibrary apply-load-rules all
    Attaching to program: `/Users/rockstar133/Library/Application Support/iPhone Simulator/User/Applications/836DC732-268E-41C7-8D30-5DD6BC965C70/PaperTopia.app/PaperTopia', process 6842.
    (gdb)
    My app basically "feeds" information from my websites database and loads images. I think some part of the internet might be wrong, idk. I am hoping this might be a simple fix.

    Thanks in advance!
  2. gojohnnyboi

    gojohnnyboi Well-Known Member

    Joined:
    Jan 25, 2008
    Messages:
    3,339
    Likes Received:
    55
    I'm not going to tell you what the error is, especially because I don't know from just looking at what you posted, but I am going to give you a helpful debugging tip to try and figure it out yourself.

    Set a breakpoint in your project for 'objc_exception_throw', and then every time your app gets thrown an exception, you'll have a useful backtrace in the debugger to look at.
  3. Rockstarou812

    Rockstarou812 New Member

    Joined:
    Jan 17, 2009
    Messages:
    43
    Likes Received:
    0
    Could you give me an example on how I would use that?
    and I wonder what the debug means by NSInvalidArgumentException

    thanks
  4. gojohnnyboi

    gojohnnyboi Well-Known Member

    Joined:
    Jan 25, 2008
    Messages:
    3,339
    Likes Received:
    55
    No, I wont tell you how to do it. It's simple, just read about breakpoints and debugging with Xcode.
  5. Cyanidepoison

    Cyanidepoison Active Member

    Joined:
    Jan 18, 2008
    Messages:
    1,076
    Likes Received:
    2
    Just to get you started, type "bt" into gdb in the debugger window and you'll get most everything you need to know to figure out a problem like that.
  6. SkylarEC

    SkylarEC Super Moderator Emeritus Staff Member

    Joined:
    Sep 19, 2007
    Messages:
    6,642
    Likes Received:
    129
    Your error is in what you posted:

    "reason: '*** -[NSURL initWithString:relativeToURL:]: nil string parameter'"

Share This Page