I posted the GDB Backtrace on the bottom and then the comments from a regular run below that(I think that's a backtrace, not 100% sure). I'll post the entire method below. I checked and I don't see any infinite recursion. I don't think I understood how to use the debugger before, but now I think I get it. I think I thought it was stopping on the first red line, but the first red line was just the first breakpoint with executable code. Now I think it stops on the first if statement. It says program received signal "EXC_BAD_ACCESS" on the first if statement. It doesn't exit on Sigbus 10 in debug mode, but does in regular run mode. I couldn't find anything wrong with my if statement, since I used the same one in a different program that runs fine.
<BLOCKQUOTE><font size="1"face="Geneva, Verdana, Arial">code:</font><HR><pre><font size=1 face=courier>
#import <font color = red>"Controller.h"</font>
<font color = purple>@implementation</font> Controller
- (<font color = green>void</font>)applicationWillFinishLaunching

NSNotification *)aNotification
{
NSLog(<font color = orange>@"Got <font color = green>this</font> far"</font>);
}
- (<font color = green>void</font>)applicationDidFinishLaunching

NSNotification *)notification
{
<font color = green>int</font> i,i1,i2,i3;
NSDictionary *d;
NSMutableString *s;
NSMutableString *tCheck;
NSString *fs = <font color = orange>@"/users/shared/BeginData"</font>;
mt = [[menuTracker alloc] init];
[<font color = purple>self</font> setUpTitles];
<font color = green>if</font> ([[NSUserDefaults standardUserDefaults] boolForKey:<font color = orange>@"hasRun"</font>] == <font color = purple>YES</font>) <font color = brown>//check <font color = green>if</font> run before</font>
{
<font color = green>if</font> ((d = [NSMutableDictionary dictionaryWithContentsOfFile:fs]) != <font color = green>nil</font>) <font color = brown>//<font color = green>if</font> user didn't delete file</font>
{
<font color = green>for</font>(i=<font color = blue>0</font>;i<<font color = blue>50</font>;i++) <font color = brown>//go through all and arrange appropriately</font>
<font color = green>if</font> ([d objectForKey:titles[i]] != <font color = green>nil</font>)
{
[tCheck setString:[d objectForKey:titles[i]]];
<font color = green>if</font> ([tCheck substringWithRange

NSRange)NSMakeRange(<font color = blue>0</font>,<font color = blue>1</font>)] == <font color = orange>@"a"</font>)
{
[tCheck deleteCharactersInRange

NSRange)NSMakeRange(<font color = blue>0</font>,<font color = blue>1</font>)]; <font color = brown>//delete prefix</font>
s = [d objectForKey

aths[i]];
[mt addApplication

NSString *)tCheck withPath

NSString *)s]; <font color = brown>//add app to menu tracker</font>
i1++;
[mt setAppNumber:i1];
}
<font color = green>if</font> ([tCheck substringWithRange

NSRange)NSMakeRange(<font color = blue>0</font>,<font color = blue>1</font>)] == <font color = orange>@"d"</font>)
{
[tCheck deleteCharactersInRange

NSRange)NSMakeRange(<font color = blue>0</font>,<font color = blue>1</font>)]; <font color = brown>//delete prefix</font>
s = [d objectForKey

aths[i]];
[mt addDocument:tCheck withPath:s]; <font color = brown>//add doc to menu tracker</font>
i2++;
[mt setDocNumber:i2];
}
<font color = green>if</font> ([tCheck substringWithRange

NSRange)NSMakeRange(<font color = blue>0</font>,<font color = blue>1</font>)] == <font color = orange>@"u"</font>)
{
[tCheck deleteCharactersInRange

NSRange)NSMakeRange(<font color = blue>0</font>,<font color = blue>1</font>)]; <font color = brown>//delete prefix</font>
s = [d objectForKey

aths[i]];
[mt addURL:tCheck withPath:s]; <font color = brown>//add URL to menu tracker</font>
i3++;
[mt setURLNumber:i3];
}
}
}
}
<font color = green>else</font>
{
[mt addApplication:<font color = orange>@"Calculator<font color = red>"</font> withPath:<font color = orange>@"</font>/Applications/Calculator"</font>];
[mt addApp];
[[NSUserDefaults standardUserDefaults] setBool:<font color = purple>YES</font> forKey:<font color = orange>@"hasRun"</font>]; <font color = brown>//say run before</font>
}
[s release];
[fs release];
[d release];
[tCheck release];
}
</font>[/code]
GDB Backtrace:
GNU gdb 5.0-20001113 (Apple version gdb-186.1) (Sun Feb 18 01:18:32 GMT 2001) (UI_OUT)
run
Copyright 2000 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 "powerpc-apple-macos10".
Reading symbols for shared libraries ... done
[Switching to thread 1 (process 317 thread 0x1903)]
MANPATH: Undefined variable.
Reading symbols for shared libraries .................................... done
Jul 28 14:23:56 Begin[317] Got this far
(gdb)
Run Comments:
Jul 28 14:25:01 Begin[329] Got this far
Begin.app has exited due to signal 10 (SIGBUS).
[ 07-28-2001: Message edited by: davecom ]