[ann][vm][unix] 3.9-4
Matej Kosik
kosik at fiit.stuba.sk
Wed May 3 22:59:32 UTC 2006
Ian Piumarta wrote:
> Folks,
>
> Source code, pre-loaded VMM image, precompiled Linux/386 and Darwin/ PPC
> binaries available.
>
> http://squeakvm.org/unix/
>
Hello,
I have observed the following problem with current (but it might be also the problem of the previous) version:
when I do not (yet) have ~/.npsqueak directory, the squeak browser plugin itself refuses
to work. It does so because it (before it executes `npsqueakrun') checks whether
the plugin image exists inside ~/.npsqueak. If not, it prints an error message
(which can be observed on stderr) and terminates. The squeaklet is not shown.
My proposal is, that the plugin should ignore the fact whether ~/.npsqueak
exists or not. It should go ahead and execute `npsqueakrun'.
Did you also notice this problem? If yes, it can be easily correct for example as follows:
The changed `npsqueak.c' file is even simpler than before.
I.e instead of this:
{
char* img_dir_v[PATH_MAX]= {user_img_dir, SYSTEM_IMG_DIR"/"};
if (findFileInPaths(plugin->imageName, imagename, 2, img_dir_v) == 0){
fprintf(stderr, "Squeak Plugin: Image file not found: %s\n",
imagename);
if (failureUrl){
fprintf(stderr, "Squeak Plugin: going to failure URL: %s\n",
failureUrl);
plugin->failureUrl= NPN_StrDup(failureUrl);
}else {
fprintf(stderr, "Squeak Plugin: no failure URL: \n");
return NPERR_GENERIC_ERROR;
}
}
plugin->argv[6]= NPN_StrDup(plugin->imageName);
}
there should be:
{
char* img_dir_v[PATH_MAX]= {user_img_dir, SYSTEM_IMG_DIR"/"};
if (findFileInPaths(plugin->imageName, imagename, 2, img_dir_v) == 0){
/* The `~/.npsqueak' directory does not exist yet. No problem.
* The `npsqueakrun' script will create it.
*/
strcpy(plugin->imageName, user_img_dir);
strcat(plugin->imageName, "/SqueakPlugin.image");
}
plugin->argv[6]= NPN_StrDup(plugin->imageName);
}
I have tried it and it worked for me.
Regards
--
Matej Kosik
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: OpenPGP digital signature
Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20060504/102c8abd/signature.pgp
More information about the Squeak-dev
mailing list
|