summaryrefslogtreecommitdiff
path: root/jvmfwk/plugins
diff options
context:
space:
mode:
authorThorsten Behrens <tbehrens@suse.com>2011-12-07 18:23:00 +0100
committerThorsten Behrens <tbehrens@suse.com>2011-12-07 18:23:00 +0100
commit5683109a4928ba3e083abfbd73e794a6784eba21 (patch)
tree0ec9e0800fbd2327ab5068784aa60775bef69458 /jvmfwk/plugins
parent13087fc6a1b024ae6d98810e31441dc60ecd7208 (diff)
Fix nasty ppc ld crash, correct default return param setting
* on OSX 10.5 PPC, ld crashes with a bus error, presumably because of the empty ar[] string array. * the "size = 0" default case looks wrong, replaced by *size=0
Diffstat (limited to 'jvmfwk/plugins')
-rw-r--r--jvmfwk/plugins/sunmajor/pluginlib/otherjre.cxx9
1 files changed, 3 insertions, 6 deletions
diff --git a/jvmfwk/plugins/sunmajor/pluginlib/otherjre.cxx b/jvmfwk/plugins/sunmajor/pluginlib/otherjre.cxx
index 864dc2d8f75d..3de9019c6c1a 100644
--- a/jvmfwk/plugins/sunmajor/pluginlib/otherjre.cxx
+++ b/jvmfwk/plugins/sunmajor/pluginlib/otherjre.cxx
@@ -87,11 +87,9 @@ char const* const* OtherInfo::getRuntimePaths(int * size)
char const* const* OtherInfo::getLibraryPaths(int* size)
{
-#ifdef UNX
+#if defined(UNX) && !defined(MACOSX)
+ //mac version does not have a ld library path anymore
static char const * ar[] = {
-#ifdef MACOSX
- //mac version does not have a ld library path anymore
-#else
"/bin",
"/jre/bin",
"/bin/classic",
@@ -102,13 +100,12 @@ char const* const* OtherInfo::getLibraryPaths(int* size)
"/lib/" JFW_PLUGIN_ARCH "/jrockit",
"/lib/" JFW_PLUGIN_ARCH "/native_threads",
"/lib/" JFW_PLUGIN_ARCH
-#endif
};
*size = sizeof(ar) / sizeof (char*);
return ar;
#else
- size = 0;
+ *size = 0;
return NULL;
#endif
}