ayaports/user/onlyoffice-document-server/core_fix-musl-build.patch

79 lines
3.4 KiB
Diff

diff --git a/core/DesktopEditor/graphics/BaseThread.cpp.orig b/core/DesktopEditor/graphics/BaseThread.cpp
index df64ee0..beba342 100644
--- a/core/DesktopEditor/graphics/BaseThread.cpp.orig
+++ b/core/DesktopEditor/graphics/BaseThread.cpp
@@ -136,7 +136,7 @@ namespace NSThreads
public:
__native_thread() : CThreadDescriptor()
{
- m_thread = NULL;
+ m_thread = 0;
}
virtual ~__native_thread()
{
diff --git a/core/DesktopEditor/cximage/CxImage/ximagif.cpp.orig b/core/DesktopEditor/cximage/CxImage/ximagif.cpp
index 4fbcf1e..fef552f 100644
--- a/core/DesktopEditor/cximage/CxImage/ximagif.cpp.orig
+++ b/core/DesktopEditor/cximage/CxImage/ximagif.cpp
@@ -86,7 +86,7 @@ namespace NSGeneratePalette
if ( ( X + Width ) > SrcWidth || ( Y + Height ) > SrcHeigth || NULL == pSrc )
{
- return NULL;
+ return 0;
}
(*pImage) = new CImage8bit ();
diff --git a/core/DesktopEditor/doctrenderer/nativecontrol.h.orig b/core/DesktopEditor/doctrenderer/nativecontrol.h
index 22a99e3..c49cc88 100644
--- a/core/DesktopEditor/doctrenderer/nativecontrol.h.orig
+++ b/core/DesktopEditor/doctrenderer/nativecontrol.h
@@ -327,7 +327,7 @@ namespace NSNativeControl
if (m_map_access_directories.end() == m_map_access_directories.find(NSFile::GetDirectoryName(strFile)))
{
- *pData = NULL;
+ *pData = 0;
dwLen = 0;
return;
}
diff --git a/core/UnicodeConverter/UnicodeConverter.cpp.orig b/core/UnicodeConverter/UnicodeConverter.cpp
index 61f1403..60d517f 100644
--- a/core/UnicodeConverter/UnicodeConverter.cpp.orig
+++ b/core/UnicodeConverter/UnicodeConverter.cpp
@@ -131,7 +131,7 @@ namespace NSUnicodeConverter
char *sResCur = sResStart;
const char *sResLimit = sResCur + nOutputLen * ucnv_getMaxCharSize(conv);
- ucnv_fromUnicode(conv, &sResCur, sResLimit, &pOutputStart, pOutputLimit, NULL, TRUE, &status);
+ ucnv_fromUnicode(conv, &sResCur, sResLimit, &pOutputStart, pOutputLimit, NULL, true, &status);
if (U_SUCCESS(status))
{
sRes = std::string(sResStart, sResCur - sResStart);
@@ -180,7 +180,7 @@ namespace NSUnicodeConverter
char *sResCur = sResStart;
const char *sResLimit = sResCur + sRes.size();
- ucnv_fromUnicode(conv, &sResCur, sResLimit, &pUCharStart, pUCharLimit, NULL, TRUE, &status);
+ ucnv_fromUnicode(conv, &sResCur, sResLimit, &pUCharStart, pUCharLimit, NULL, true, &status);
if (U_SUCCESS(status))
{
sRes.resize(sResCur - sResStart);
@@ -223,7 +223,7 @@ namespace NSUnicodeConverter
UChar* target = targetStart;
UChar* targetLimit = target + uBufSize;
- ucnv_toUnicode(conv, &target, targetLimit, &source, sourceLimit, NULL, TRUE, &status);
+ ucnv_toUnicode(conv, &target, targetLimit, &source, sourceLimit, NULL, true, &status);
if (U_SUCCESS(status))
{
size_t nTargetSize = target - targetStart;
@@ -278,7 +278,7 @@ namespace NSUnicodeConverter
UChar* target = targetStart;
UChar* targetLimit = target + uBufSize;
- ucnv_toUnicode(conv, &target, targetLimit, &source, sourceLimit, NULL, TRUE, &status);
+ ucnv_toUnicode(conv, &target, targetLimit, &source, sourceLimit, NULL, true, &status);
if (U_SUCCESS(status))
{
size_t nTargetSize = target - targetStart;