include/comphelper/windowserrorstring.hxx | 3 +++ 1 file changed, 3 insertions(+)
New commits: commit 4aee1237a59808cbd58c9c02870063d5a7156710 Author: Tor Lillqvist <t...@collabora.com> Date: Fri Jun 3 10:59:57 2016 +0300 Strip also a CR if there (and there seems to be such) Sad that it took so long for me to notice. Change-Id: I14b8a61930bb0b2dd1c5e9cce2a6c3e375dcb6ed diff --git a/include/comphelper/windowserrorstring.hxx b/include/comphelper/windowserrorstring.hxx index 1da7e9c..d47ff65 100644 --- a/include/comphelper/windowserrorstring.hxx +++ b/include/comphelper/windowserrorstring.hxx @@ -32,6 +32,9 @@ inline OUString WindowsErrorString(DWORD nErrorCode) if (pMsgBuf[wcslen(pMsgBuf)-1] == '\n') pMsgBuf[wcslen(pMsgBuf)-1] = '\0'; + if (pMsgBuf[wcslen(pMsgBuf)-1] == '\r') + pMsgBuf[wcslen(pMsgBuf)-1] = '\0'; + OUString result(pMsgBuf); LocalFree(pMsgBuf); _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits