Gregory John Casamento <[EMAIL PROTECTED]> writes:

> In every case, all files .gorm and non-gorm archives are failing when
> unarchiving NS*Number objects.
>
> I believe that since the NS*Number objects are cached the release done by the
> assign at the following location in NSUnarchiver is causing the crash I'm
> seeing:
>
>
> FROM NSUnarchiver:
>                 obj = [c allocWithZone: zone];
>                 /*
>                  * The objMap array does not retain its contents directly,
>                  * so we perform explicit retain/release as we add objects
>                  * to and remove objects from the array.
>                  */
>                 RETAIN(obj);
>                 GSIArrayAddItem(objMap, (GSIArrayItem)obj);
>
>                 rep = [obj initWithCoder: self];
>                 if (rep != obj)
>                   {
> ---> Dying here!!     ASSIGN(obj, rep);
>                     GSIArraySetItemAtIndex(objMap, (GSIArrayItem)obj, xref);
>                   }

That was exactly the reason that my patch did NOT have any code 
here to change the retain count.  My code might be wrong,
but I think this is wrong as well.

Fortunately I am not at work :-), but that means I can not
test and take a carefull look at the issue.  But I will study the
new patches.

Wim Oudshoorn.




_______________________________________________
Bug-gnustep mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/bug-gnustep

Reply via email to