diff options
author | Caolán McNamara <caolanm@redhat.com> | 2010-10-18 15:42:48 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2010-10-18 15:42:48 +0100 |
commit | 34f1c06830ae530bea4f11aca91e2836a53fd764 (patch) | |
tree | e5511625119420cff7083c26466af559802c1d23 /svx/source/gengal | |
parent | a8e4476824a8ad0be01b4116a00cd48c145961bb (diff) |
#i112656# add osl_setEnvironment and osl_clearEnvironment
Diffstat (limited to 'svx/source/gengal')
-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 0f2bf53338e8..856ed4742a04 100644 --- a/svx/source/gengal/gengal.cxx +++ b/svx/source/gengal/gengal.cxx @@ -242,8 +242,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" ) ); |