On Mon, Apr 5, 2010 at 1:48 AM, Rainer Tammer <tam...@tammer.net> wrote:

> what exactly did you change do fix the
> /Users/bjskelly/4.0.1/ooRexx/base/bif/VALUE.testGroup in 32 bit mode ???

Rainer,

We talked about this back in 10/1/2009.  You can look up the thread in
the archives:

https://sourceforge.net/mailarchive/forum.php?thread_name=5d74c5720910011026p678f1aa0u6ab0afb28abbde76%40mail.gmail.com&forum_name=oorexx-devel

We decided to rewrite the whole area involved for the next release,
and I said I would do the rewirte.

For this bug release, neither Rick nor I were in favor of including
that fix.  I would prefer to leave it for the next major release.

>From the past discussion, we have this simplistic fix:

Index: interpreter/platform/unix/ValueFunction.cpp
===================================================================
--- interpreter/platform/unix/ValueFunction.cpp (revision 5228)
+++ interpreter/platform/unix/ValueFunction.cpp (working copy)
@@ -103,11 +103,16 @@
       del = *Environment;              /* remember it for deletion          */
   }

-  if (Value != (RexxString *) TheNilObject)
+  if (Value == (RexxString *) TheNilObject)
   {
+    sprintf(Env_Var_String, "%s=%s",Name->getStringData(),"");
+  }
+  else
+  {
     sprintf(Env_Var_String,
"%s=%s",Name->getStringData(),Value->getStringData());
-    putenv(Env_Var_String);
   }
+  putenv(Env_Var_String);
+
   if(del)                              /* if there was a old one            */
     free(del);                         /* free it                           */
   return 0;                            /* return success                    */


But, there are 3 different areas in the code that need to be fixed and
the simplistic fix is not sufficient.  Really it needs to be
completely rewritten to use unsetenv(), getenv(), and setenv().

--
Mark Miesfeld

------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel

Reply via email to