diff --git a/ChangeLog b/ChangeLog index d29cf88b2..81db8a770 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2010-04-13 Richard Frith-Macdonald + + * Source/NSArray.m: ([-initWithContentsOfFile:]) added ugly OSX + compatibility hack ... return the mutable array deserialized from + the property list rather than an instance of the same class as + the receiver. The original GNUstep behavior made more sense. + 2010-04-13 Richard Frith-Macdonald * Source/NSNotificationQueue.m: Fix error traversing queue. diff --git a/Source/NSArray.m b/Source/NSArray.m index fbe12fba5..72dc664e4 100644 --- a/Source/NSArray.m +++ b/Source/NSArray.m @@ -796,7 +796,12 @@ static SEL rlSel; RELEASE(myString); if ([result isKindOfClass: NSArrayClass]) { - self = [self initWithArray: result]; + //self = [self initWithArray: result]; + /* OSX appears to always return a mutable array rather than + * the class of the receiver. + */ + RELEASE(self); + self = RETAIN(result); } else {