[omniORB] OMNIORB_CONFIG environment variable ignored?

Matej Kenda matejkenda@volja.net
Fri Jan 24 11:51:01 2003


matejkenda@volja.net wrote:

>Hi,
>
>The documentation of omniORB says that location of configuration can be
>specified by using OMNIORB_CONFIG environment variable.
>
>In our implementation the environment variable is exported in C++ code
>(setenv()) just before calling ORB_init. This worked in omniORB 3, but
>it
>doesn't in omniORB 4.
>
>The output from our application and omniORB:
>
> Set environment  variable:"OMNIORB_CONFIG=/etc/opt/ivd/omniORB.cfg"
> Set environment variable:"ORBmaxGIOPConnectionPerServer=64"
> omniORB: Read from configuration file "/etc/omniORB.cfg".
>
>  
>
I added some additional logging code in the libomniORB4.so and found out 
that the environment variable can't be read in the shared library if 
exported by putenv(), but it can be successfully read if setenv() with 
override is used.

I don't know the reason, though, because it can be read in my source 
code if exported in any way.

Regards,

Matej