bug-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Segfault when sending a message to a protocol


From: Stefan Urbanek
Subject: Segfault when sending a message to a protocol
Date: Wed, 18 Sep 2002 18:28:20 +0100

Hi,

I get segfault when sending a message to a protocol. I have noticed it when i 
was not able to sent some messages to distant objects. Then I realized that I 
am not able to send those mesaages that were included in the protocol that was 
set to the proxy with setProtocolForProxy:.

Here is bactrace:

#0  0x4023ec6f in objc_msg_lookup () from /usr/local/lib/libobjc.so.1
#1  0x080488ec in gnustep_base_user_main (argc=1, argv=0xbffff324) at test.m:16
#2  0x40148859 in main ()
  from 
/usr/GNUstep/System/Libraries/ix86/linux-gnu/gnu-gnu-gnu/libgnustep-base.so.1
#3  0x4034714f in __libc_start_main () from /lib/libc.so.6

And here is an example that will crash:

----

#import <Foundation/NSAutoreleasePool.h>
#import <Foundation/NSObject.h>
#import <Foundation/NSString.h>

int main(int argc, const char **argv)
{       
   NSAutoreleasePool *pool;
   Protocol          *p;

   pool = [NSAutoreleasePool new];

   p = @protocol(NSObject);
   NSLog(@"Protocol test %p",p);
   /* Crash here ...*/
   NSLog(@"Description   %p",[p descriptionForInstanceMethod:@selector(class)]);

   RELEASE(pool);

   return 0;
}

----

Whan should be wrong?

Thank you,

Stefan





reply via email to

[Prev in Thread] Current Thread [Next in Thread]