[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: differences between gnustep and libFoundation while porting ogo
From: |
Sebastian Reitenbach |
Subject: |
Re: differences between gnustep and libFoundation while porting ogo |
Date: |
Thu, 12 Feb 2009 10:14:00 +0100 |
User-agent: |
KMail/1.9.9 |
Hi Richard,
thanks a lot for looking into this.
On Thursday 12 February 2009 09:38:39 am you wrote:
> On 12 Feb 2009, at 07:16, Sebastian Reitenbach wrote:
> > class: NSException
> > name: NSGenericException
> > reason: subclass WOHTTPURLHandle(class) should override
> > cachedHandleForURL:
> > info:
> >
> > So I took a look what GSHTTPURLHandler is doing, and for now I added
> > the
> > following to WOHTTPURLHandle class in SOPE:
> > + (NSURLHandle*) cachedHandleForURL: (NSURL*)newUrl
> > {
> > NSURLHandle *obj = nil;
> > return obj;
> > }
> >
> > that made the problem disappear. As helge always says, it works for
> > him on
> > libFoundation and on Cocoa, the difference seems to be in GNUstep ???
>
> I wrote a testcase for this, and confirmed that the GNUstep behavior
> (raising an exception here) is the same on GNUstep and MacOS-X.
> So I would guess that any problem lies somewhere else in the code.
> Perhaps GNUstep is attempting to use a cached URL where libFoundation
> isn't attempting caching?
I'll guess, that might probably the case here.
Now I know that by adding the method above to sope, was not too wrong.
>
> > Getting that out of the way, made me run into the next exception:
> > Application Server caught exception:
>
> <snip>
>
> > So it seems, on libFoundation I can initialize a NSString with a
> > nil string,
> > but not on GNUstep. I also have no idea which one is the right one.
>
> Thanks ... I just wrote a test for this on MacOS-X (and added it to
> the GNUstep base regression testsuite). The GNUstep behavior is the
> same as the MacOS-X behavior ... to raise an exception. I don't see
> how the code section calling -initWithString: with a nil argument
> could possibly work on MacOS-X.
I only tested it linked against libFoundation, and IIRC, it worked there.
However, I now know that need to check whether a string is nil before I
initialize another string with it.
thanks a lot for your fast and valuable help
Sebastian