[squeak-dev] Re: UI lockup in Squeak 4.1

Rob Withers reefedjib at yahoo.com
Tue Jul 13 20:53:57 UTC 2010


> From: Eliot Miranda
> Sent: Tuesday, July 13, 2010 4:11 PM
> To: The general-purpose Squeak developers list
> Subject: Re: [squeak-dev] Re: UI lockup in Squeak 4.1
>
>
>
>
>
> > On Tue, Jul 13, 2010 at 12:59 PM, Rob Withers <reefedjib at yahoo.com> 
> > wrote:
> >
> > Hi Eliot,
> >
> >
> > I already found it.
> >
>
> Doh!
>
> >  It is this method, when the result of the dictionary lookup is nil for 
> > 'en', and it recursively calls localeID: with 'en'.
> >
> >
> > LanguageEnvironment class>>#localeID: localeID
> > ^self knownEnvironments at: localeID ifAbsent: [self localeID: (LocaleID
> > isoLanguage: 'en')]
> >
>
>
> which clearly needs to read something like
>  LanguageEnvironment class>>#localeID: localeID
>     ^self knownEnvironments
>         at: localeID
>         ifAbsent: [self knownEnvironments at: (LocaleID isoLanguage: 
> 'en')]
>

The problem is that something changed the entry for 'en' from 
Latin1Environment to nil.  So the absent block will still fail, although 
this time as an Error and not a recursive, memory-growing loop.

I had in mind:
LanguageEnvironment class>>#localeID: localeID

    ^self knownEnvironments
        at: localeID
        ifAbsent: [
            | env id |
            env := Latin1Environment new.
            id := LocaleID isoString: 'en'.
            env localeID: id.
            self knownEnvironments at: id put: env.
            ^ env].


>
> > I start the image with an intact KnownEnvironments.   Something somehow 
> > nils out the entries after I > > > have run for awhile.   ??????
> >
>
> So guard against resetKnownEnvironments?

I had a 'self halt' and it never got called.

I have no idea how it was nilling out the entries.

Rob





More information about the Squeak-dev mailing list