Kaydet (Commit) f9d2bfec authored tarafından Stephan Bergmann's avatar Stephan Bergmann

fprintf -> SAL_INFO

Change-Id: I4808e89cf5b90c99df3d4c4474c578a8c8f611a6
üst 0123bbbc
...@@ -28,9 +28,6 @@ ...@@ -28,9 +28,6 @@
# include <dlfcn.h> # include <dlfcn.h>
#endif #endif
#if OSL_DEBUG_LEVEL > 0
#include <stdio.h>
#endif
#include <string.h> #include <string.h>
#include "boost/scoped_array.hpp" #include "boost/scoped_array.hpp"
......
...@@ -61,11 +61,8 @@ bool isVendorSupported(const OUString& sVendor) ...@@ -61,11 +61,8 @@ bool isVendorSupported(const OUString& sVendor)
if (sVendor.equalsAscii(gVendorMap[pos].sVendorName)) if (sVendor.equalsAscii(gVendorMap[pos].sVendorName))
return true; return true;
} }
#if OSL_DEBUG_LEVEL >= 2 SAL_INFO(
OString sVendorName = OUStringToOString(sVendor, osl_getThreadTextEncoding()); "jfw.level2", "sunjavaplugin does not support vendor: " << sVendor);
fprintf(stderr, "[Java frameworksunjavaplugin.so]sunjavaplugin does not support vendor: %s.\n",
sVendorName.getStr());
#endif
return false; return false;
} }
......
...@@ -239,11 +239,9 @@ std::vector<OUString> VendorSettings::getSupportedVendors() ...@@ -239,11 +239,9 @@ std::vector<OUString> VendorSettings::getSupportedVendors()
OString sParam = OString sParam =
OUStringToOString(sValue, osl_getThreadTextEncoding()); OUStringToOString(sValue, osl_getThreadTextEncoding());
vecParams.push_back(sParam); vecParams.push_back(sParam);
#if OSL_DEBUG_LEVEL >=2 SAL_INFO(
OString sParamName = OUStringToOString(sName, osl_getThreadTextEncoding()); "jfw.level2",
fprintf(stderr,"[Java framework] Using bootstrap parameter %s" "Using bootstrap parameter " << sName << " = " << sParam);
" = %s.\n", sParamName.getStr(), sParam.getStr());
#endif
} }
else else
break; break;
...@@ -270,10 +268,10 @@ OString BootParams::getClasspath() ...@@ -270,10 +268,10 @@ OString BootParams::getClasspath()
sCP)) sCP))
{ {
sClassPath = OUStringToOString(sCP, osl_getThreadTextEncoding()); sClassPath = OUStringToOString(sCP, osl_getThreadTextEncoding());
#if OSL_DEBUG_LEVEL >=2 SAL_INFO(
fprintf(stderr,"[Java framework] Using bootstrap parameter " "jfw.level2",
UNO_JAVA_JFW_CLASSPATH " = %s.\n", sClassPath.getStr()); "Using bootstrap parameter " UNO_JAVA_JFW_CLASSPATH " = "
#endif << sClassPath);
} }
OUString sEnvCP; OUString sEnvCP;
...@@ -287,10 +285,10 @@ OString BootParams::getClasspath() ...@@ -287,10 +285,10 @@ OString BootParams::getClasspath()
char szSep[] = {SAL_PATHSEPARATOR,0}; char szSep[] = {SAL_PATHSEPARATOR,0};
sClassPath += OString(szSep) + OString(pCp); sClassPath += OString(szSep) + OString(pCp);
} }
#if OSL_DEBUG_LEVEL >=2 SAL_INFO(
fprintf(stderr,"[Java framework] Using bootstrap parameter " "jfw.level2",
UNO_JAVA_JFW_ENV_CLASSPATH " and class path is:\n %s.\n", pCp ? pCp : ""); "Using bootstrap parameter " UNO_JAVA_JFW_ENV_CLASSPATH
#endif " and class path is: " << (pCp ? pCp : ""));
} }
return sClassPath; return sClassPath;
...@@ -326,11 +324,10 @@ OUString BootParams::getVendorSettings() ...@@ -326,11 +324,10 @@ OUString BootParams::getVendorSettings()
UNO_JAVA_JFW_VENDOR_SETTINGS)); UNO_JAVA_JFW_VENDOR_SETTINGS));
} }
} }
#if OSL_DEBUG_LEVEL >=2 SAL_INFO(
OString sValue = OUStringToOString(sVendor, osl_getThreadTextEncoding()); "jfw.level2",
fprintf(stderr,"[Java framework] Using bootstrap parameter " "Using bootstrap parameter " UNO_JAVA_JFW_VENDOR_SETTINGS " = "
UNO_JAVA_JFW_VENDOR_SETTINGS" = %s.\n", sValue.getStr()); << sVendor);
#endif
} }
return sVendor; return sVendor;
} }
...@@ -372,10 +369,10 @@ OUString BootParams::getJREHome() ...@@ -372,10 +369,10 @@ OUString BootParams::getJREHome()
JFW_E_ERROR, JFW_E_ERROR,
OString("[Java framework] Error in function BootParams::getJREHome() " OString("[Java framework] Error in function BootParams::getJREHome() "
"(fwkbase.cxx).")); "(fwkbase.cxx)."));
#if OSL_DEBUG_LEVEL >=2 SAL_INFO(
fprintf(stderr,"[Java framework] Using bootstrap parameter " "jfw.level2",
UNO_JAVA_JFW_ENV_JREHOME" with JAVA_HOME = %s.\n", pJRE); "Using bootstrap parameter " UNO_JAVA_JFW_ENV_JREHOME
#endif " with JAVA_HOME = " << pJRE);
} }
else if (getMode() == JFW_MODE_DIRECT else if (getMode() == JFW_MODE_DIRECT
&& !bEnvJRE && !bEnvJRE
...@@ -388,14 +385,9 @@ OUString BootParams::getJREHome() ...@@ -388,14 +385,9 @@ OUString BootParams::getJREHome()
" must be set in direct mode.")); " must be set in direct mode."));
} }
#if OSL_DEBUG_LEVEL >=2 SAL_INFO_IF(
if (bJRE == sal_True) bJRE, "jfw.level2",
{ "Using bootstrap parameter " UNO_JAVA_JFW_JREHOME " = " << sJRE);
OString sValue = OUStringToOString(sJRE, osl_getThreadTextEncoding());
fprintf(stderr,"[Java framework] Using bootstrap parameter "
UNO_JAVA_JFW_JREHOME" = %s.\n", sValue.getStr());
}
#endif
return sJRE; return sJRE;
} }
...@@ -405,11 +397,10 @@ OUString BootParams::getClasspathUrls() ...@@ -405,11 +397,10 @@ OUString BootParams::getClasspathUrls()
Bootstrap::get()->getFrom( Bootstrap::get()->getFrom(
OUString(UNO_JAVA_JFW_CLASSPATH_URLS), OUString(UNO_JAVA_JFW_CLASSPATH_URLS),
sParams); sParams);
#if OSL_DEBUG_LEVEL >=2 SAL_INFO(
OString sValue = OUStringToOString(sParams, osl_getThreadTextEncoding()); "jfw.level2",
fprintf(stderr,"[Java framework] Using bootstrap parameter " "Using bootstrap parameter " UNO_JAVA_JFW_CLASSPATH_URLS " = "
UNO_JAVA_JFW_CLASSPATH_URLS " = %s.\n", sValue.getStr()); << sParams);
#endif
return sParams; return sParams;
} }
......
...@@ -29,10 +29,6 @@ ...@@ -29,10 +29,6 @@
#include "rtl/ustrbuf.hxx" #include "rtl/ustrbuf.hxx"
#include "rtl/byteseq.hxx" #include "rtl/byteseq.hxx"
#include "osl/thread.hxx" #include "osl/thread.hxx"
#if OSL_DEBUG_LEVEL >=2
#include <stdio.h>
#endif
namespace jfw namespace jfw
{ {
...@@ -58,10 +54,7 @@ struct Bootstrap : ...@@ -58,10 +54,7 @@ struct Bootstrap :
buf.appendAscii(SAL_CONFIGFILE("/jvmfwk3")); buf.appendAscii(SAL_CONFIGFILE("/jvmfwk3"));
OUString sIni = buf.makeStringAndClear(); OUString sIni = buf.makeStringAndClear();
::rtl::Bootstrap * bootstrap = new ::rtl::Bootstrap(sIni); ::rtl::Bootstrap * bootstrap = new ::rtl::Bootstrap(sIni);
#if OSL_DEBUG_LEVEL >=2 SAL_INFO("jfw.level2", "Using configuration file " << sIni);
OString o = OUStringToOString( sIni , osl_getThreadTextEncoding() );
fprintf(stderr, "[Java framework] Using configuration file %s\n" , o.getStr() );
#endif
return bootstrap; return bootstrap;
} }
}; };
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment