diff options
Diffstat (limited to 'svx/source/gengal/gengal.cxx')
-rw-r--r-- | svx/source/gengal/gengal.cxx | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/svx/source/gengal/gengal.cxx b/svx/source/gengal/gengal.cxx index bc8e6ef7c4bd..4120027c3e35 100644 --- a/svx/source/gengal/gengal.cxx +++ b/svx/source/gengal/gengal.cxx @@ -241,8 +241,9 @@ void GalApp::Init() #endif rtl::OUString baseBinDir = fileName.copy( 0, lastSlash ); rtl::OUString installPrefix = baseBinDir + rtl::OUString::createFromAscii( "/../.." ); - rtl::OUString assignment = rtl::OUString::createFromAscii( "OOO_INSTALL_PREFIX=" ) + installPrefix; - putenv( strdup( OUSTRING_CSTR( assignment ))); + + rtl::OUString envVar(RTL_CONSTASCII_USTRINGPARAM("OOO_INSTALL_PREFIX")); + osl_setEnvironment(envVar.pData, installPrefix.pData); } OSL_TRACE( "OOO_INSTALL_PREFIX=%s", getenv( "OOO_INSTALL_PREFIX" ) ); |