You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openoffice.apache.org by ar...@apache.org on 2022/01/07 09:09:18 UTC
[openoffice] 01/04: Decode APR errors and display them
This is an automated email from the ASF dual-hosted git repository.
ardovm pushed a commit to branch serf
in repository https://gitbox.apache.org/repos/asf/openoffice.git
commit 56c8a34d623b90b13dee9379422621b1de33b38d
Author: Arrigo Marchiori <ar...@yahoo.it>
AuthorDate: Tue Dec 21 22:15:06 2021 +0100
Decode APR errors and display them
---
main/ucb/source/ucp/webdav/SerfRequestProcessor.cxx | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/main/ucb/source/ucp/webdav/SerfRequestProcessor.cxx b/main/ucb/source/ucp/webdav/SerfRequestProcessor.cxx
index e378630..8806e32 100644
--- a/main/ucb/source/ucp/webdav/SerfRequestProcessor.cxx
+++ b/main/ucb/source/ucp/webdav/SerfRequestProcessor.cxx
@@ -552,7 +552,14 @@ void SerfRequestProcessor::postprocessProcessor( const apr_status_t inStatus )
break;
default:
- mpDAVException = new DAVException( DAVException::DAV_HTTP_ERROR );
+ {
+ // APR can help us describe this error
+ char *buff = new char[512];
+ apr_strerror(inStatus, buff, 512);
+ rtl::OUString message(buff, strlen(buff), RTL_TEXTENCODING_DONTKNOW);
+ delete[] buff;
+ mpDAVException = new DAVException( DAVException::DAV_HTTP_ERROR, message );
+ }
break;
}
}