Can anyone on MSYS2 replicate this recipe for crashing GDB?

1. Install MSYS2. Update pacman.

2. Install packages and build GS (modules/scripts).

3. Build the program below and run gdb on it.


gdb commands:

b main
r
tbreak 10 # in front of the return
c
print [ud objectForKey:@"foo”] # GDB crashes


program:

#import <Foundation/Foundation.h>

int main( int argc, const char *argv[] )
{
    id pool = [NSAutoreleasePool new];
    id ud   = [NSUserDefaults standardUserDefaults];
    id foo  = [ud objectForKey:@"foo"];
    printf("foo = %s\n", foo ? [foo cString] : "missing"); fflush(stdout);
    [pool release];
#line 10
    return 0;
}



Note:

Using old MSYS GNUstep installed from Installers, it crashes right on “b main” 
(as previously reported) and if update all packages with mingw-get and rebuild 
GNUstep, it crashes as above.
_______________________________________________
Gnustep-dev mailing list
Gnustep-dev@gnu.org
https://lists.gnu.org/mailman/listinfo/gnustep-dev

Reply via email to