summaryrefslogtreecommitdiff
path: root/desktop/source
diff options
context:
space:
mode:
authorRohan Kumar <rohankanojia420@gmail.com>2016-03-09 02:16:47 +0530
committerBjörn Michaelsen <bjoern.michaelsen@canonical.com>2016-03-12 14:35:40 +0000
commit221144f9c995fe30adf577c02f756b3123fb2550 (patch)
treeed4f260d8b78016ff972306b8735ad65fbcbffe0 /desktop/source
parent1151fec7a8c3dfcbc364aa941f477004309b1e59 (diff)
tdf#91794 OSL_DEBUG_LEVEL > 1 removed (desktop)
[UPDATED PATCH]: I removed the trailing newline characters in the SAL_WARN macro as pointed by Jan Iverson Change-Id: If90b0d44777ec2ab1bd646f22f4c9cdf798cf8b4 Reviewed-on: https://gerrit.libreoffice.org/22315 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Björn Michaelsen <bjoern.michaelsen@canonical.com>
Diffstat (limited to 'desktop/source')
-rw-r--r--desktop/source/app/officeipcthread.cxx15
-rw-r--r--desktop/source/deployment/registry/dp_registry.cxx2
-rw-r--r--desktop/source/splash/unxsplash.cxx21
3 files changed, 13 insertions, 25 deletions
diff --git a/desktop/source/app/officeipcthread.cxx b/desktop/source/app/officeipcthread.cxx
index 6bf4dc56dee1..e9ad39b30b0b 100644
--- a/desktop/source/app/officeipcthread.cxx
+++ b/desktop/source/app/officeipcthread.cxx
@@ -249,10 +249,7 @@ rtl::Reference< OfficeIPCThread > OfficeIPCThread::pGlobalOfficeIPCThread;
// Into a hex string of well known length ff132a86...
OUString CreateMD5FromString( const OUString& aMsg )
{
-#if (OSL_DEBUG_LEVEL > 2)
- fprintf( stderr, "create md5 from '%s'\n",
- OUStringToOString (aMsg, RTL_TEXTENCODING_UTF8).getStr() );
-#endif
+ SAL_WARN("desktop.app", "create md5 from '" << aMsg << "'");
rtlDigest handle = rtl_digest_create( rtl_Digest_AlgorithmMD5 );
if ( handle )
@@ -750,8 +747,8 @@ void OfficeIPCThread::execute()
}
catch ( const CommandLineArgs::Supplier::Exception & )
{
-#if (OSL_DEBUG_LEVEL > 1) || defined DBG_UTIL
- fprintf( stderr, "Error in received command line arguments\n" );
+#if (OSL_DEBUG_LEVEL > 0) || defined DBG_UTIL
+ SAL_WARN("desktop.app", "Error in received command line arguments");
#endif
continue;
}
@@ -955,7 +952,7 @@ void OfficeIPCThread::execute()
PROCESSING_DONE, SAL_N_ELEMENTS(PROCESSING_DONE));
// incl. terminating NUL
if (n != SAL_N_ELEMENTS(PROCESSING_DONE)) {
- SAL_WARN("desktop", "short write: " << n);
+ SAL_WARN("desktop" , "short write: " << n);
continue;
}
}
@@ -969,8 +966,8 @@ void OfficeIPCThread::execute()
}
}
-#if (OSL_DEBUG_LEVEL > 1) || defined DBG_UTIL
- fprintf( stderr, "Error on accept: %d\n", (int)nError );
+#if (OSL_DEBUG_LEVEL > 0) || defined DBG_UTIL
+ SAL_WARN( "desktop.app", "Error on accept: " << (int)nError);
#endif
TimeValue tval;
tval.Seconds = 1;
diff --git a/desktop/source/deployment/registry/dp_registry.cxx b/desktop/source/deployment/registry/dp_registry.cxx
index 4c072281cda4..6faba93a2b5b 100644
--- a/desktop/source/deployment/registry/dp_registry.cxx
+++ b/desktop/source/deployment/registry/dp_registry.cxx
@@ -376,7 +376,7 @@ Reference<deployment::XPackageRegistry> PackageRegistryImpl::create(
create_folder( nullptr, registryCachePath, Reference<XCommandEnvironment>());
-#if OSL_DEBUG_LEVEL > 1
+#if OSL_DEBUG_LEVEL > 0
// dump tables:
{
t_registryset allBackends;
diff --git a/desktop/source/splash/unxsplash.cxx b/desktop/source/splash/unxsplash.cxx
index c396fc5f6b18..4018535f81e2 100644
--- a/desktop/source/splash/unxsplash.cxx
+++ b/desktop/source/splash/unxsplash.cxx
@@ -36,10 +36,7 @@ namespace desktop
UnxSplashScreen::~UnxSplashScreen()
{
-#if OSL_DEBUG_LEVEL > 1
- fprintf( stderr, "UnxSplashScreen::~UnxSplashScreen()\n" );
-#endif
-
+ SAL_WARN("desktop.splash", "UnxSplashScreen::~UnxSplashScreen()");
if ( m_pOutFd )
{
fclose( m_pOutFd );
@@ -55,9 +52,7 @@ void SAL_CALL UnxSplashScreen::start( const OUString& /*aText*/, sal_Int32 /*nRa
void SAL_CALL UnxSplashScreen::end()
throw ( uno::RuntimeException, std::exception )
{
-#if OSL_DEBUG_LEVEL > 1
- fprintf( stderr, "UnxSplashScreen::end()\n" );
-#endif
+ SAL_WARN("desktop.splash", "UnxSplashScreen::end()");
if( !m_pOutFd )
return;
@@ -68,9 +63,7 @@ void SAL_CALL UnxSplashScreen::end()
void SAL_CALL UnxSplashScreen::reset()
throw ( uno::RuntimeException, std::exception )
{
-#if OSL_DEBUG_LEVEL > 1
- fprintf( stderr, "UnxSplashScreen::reset()\n" );
-#endif
+ SAL_WARN("desktop.splash", "UNXSplashScreen::reset()");
if( !m_pOutFd )
return;
@@ -108,11 +101,9 @@ UnxSplashScreen::initialize( const css::uno::Sequence< css::uno::Any>& )
{
int fd = aNum.toInt32();
m_pOutFd = fdopen( fd, "w" );
-#if OSL_DEBUG_LEVEL > 1
- fprintf( stderr, "Got argument '--splash-pipe=%d ('%s') (%p)\n",
- fd, OUStringToOString( aNum, RTL_TEXTENCODING_UTF8 ).getStr(),
- m_pOutFd );
-#endif
+ SAL_WARN("desktop.splash", "Got argument '--splash-pipe=" << fd << " ('"
+ << aNum << "') ("
+ << static_cast<void *>(m_pOutFd) << ")");
}
}
}