Re: Possible angle on JPL failures
[email protected] Fri, 9 Feb 2001 12:16:25 -0800 (PST)
| Newsgroups | perl.jpl |
|---|---|
| Message-ID | <[email protected]> |
> <image> Shamefaced emergence from the shadows </image> > Oh man, I'm so far behind I'm even late for my own diss'n :) > I have no time to persue this with p5p; I'm barely even keeping up > with traffic there without trying to engage in dialog :/ I have tagged > the second version of the patch in my jpl mailbox and will try and > remember the access sequence for the CVS repository (hint, hint Brian) > so I can see if I can find time to at least prod p5p if noone else > beats me to it. Stephen, Thanks for emerging :) I sent the following to p5p. The patch is a tiny bit different than earlier ones. No response from p5p. Rgds, -- Charles DeRykus From [email protected] Wed Jan 31 12:37:42 2001 ... Message-Id: <[email protected]> To: [email protected] Subject: JPL hack Content-Length: 2524 Status: RO There have been persistent JPL failures/cores with jdk1.2/1.3. Some brute force debugging on Solaris 2.7 revealed that Java is apparently no longer tolerant of native code diddling the environment. I don't know Java well but someone suggested Java's heavier internal threading may have become a problem. Here's a quick hack that gets JPL working with an environment dup. I've verified that this works on Solaris 2.7 with both 5.6.0 and 5.005_03. (By works, I mean doesn't get a segv/ problematic thread core dump with the Sample program in the JPL distribution.) JPL is a key tool for several projects here. Any chance of some fluent variant of this getting implemented? Other workarounds? Rgds, -- Charles DeRykus *** perl.c Tue Jan 30 18:06:05 2001 --- perl.c.orig Fri Mar 17 14:35:15 2000 *************** *** 11,22 **** * "A ship then new they built for him/of mithril and of elven glass" --Bilbo */ - /* dup environment if JPL */ - #ifdef JPL - char **my_env_base, **env_base, **my_env; - int my_env_count = 0; - #endif - #include "EXTERN.h" #define PERL_IN_PERL_C #include "perl.h" --- 11,16 ---- *************** *** 3204,3239 **** env = environ; if (env != environ) environ[0] = Nullch; - #ifdef JPL - env_base = env; - for (; *env; env++) - my_env_count++; - my_env = (char **) safemalloc( sizeof(char *) * (my_env_count+1) ); - my_env_base = my_env; - env = env_base; - for (; *env; env++, my_env++) { - *my_env = (char *) safemalloc( sizeof(char) * (strlen(*env)+1) ); - strcpy( *my_env, *env ); - } - *my_env = '\0'; - my_env = my_env_base; - for (; *my_env; my_env++) { - if ( !(s = strchr(*my_env,'='))) - continue; - *s++ = '\0'; - #if defined(MSDOS) - (void)strupr(*my_env); - #endif - sv = newSVpv(s--,0); - (void)hv_store(hv, *my_env, s - *my_env, sv, 0); - *s = '='; - #if defined(__BORLANDC__) && defined(USE_WIN32_RTL_ENV) - /* Sins of the RTL. See note in my_setenv(). */ - (void)PerlEnv_putenv(savepv(*my_env)); - #endif - } - /* non-JPL */ - #else for (; *env; env++) { if (!(s = strchr(*env,'='))) continue; --- 3198,3203 ---- *************** *** 3250,3256 **** #endif } #endif - #endif #ifdef DYNAMIC_ENV_FETCH HvNAME(hv) = savepv(ENV_HV_NAME); #endif --- 3214,3219 ----