[BUG] SqueakMap 1.09 loading fails

goran.krampe at bluefish.se goran.krampe at bluefish.se
Thu Oct 9 09:56:15 UTC 2003


Avi Bryant <avi at beta4.com> wrote:
> 
> On Thu, 9 Oct 2003 goran.krampe at bluefish.se wrote:
> 
> > Ok, just change SMMcInstaller>>install to:
> > install
> > 	"This service should bring the package to the client,
> > 	unpack it if necessary and install it into the image.
> > 	The package is notified of the installation."
> >
> > 	self download; fileIn.
> > 	package noteInstalled
> >
> > ---
> > That should do it. So if you do this fix in MCInstaller and... hrm. Ok,
> > so moving this class to SqueakMap Base was perhaps not so smart then.
> > Whatever, it's in there now anyway.
> 
> Ok, done.  But will MCInstaller still be broken with old versions of SM,
> now, or does that method work with both?

Hmmm. This makes my head hurt. :-) Well, perhaps you should write it
like this instead:

install
	"This service should bring the package to the client,
	unpack it if necessary and install it into the image.
	The package is notified of the installation."

	| result |
	result _ self download.
	(result ~= self and: [result not]) ifTrue: [^false]
	self fileIn.
	package noteInstalled.
	^true


The old SM returns false if download fails, true otherwise. The new SM
always returns self or raises an exception.

regards, Göran



More information about the Squeak-dev mailing list