freebsd-ports/audio/libcoverart/files/patch-src_xmlParser.cpp
Jason E. Hale ebd334649f Fix build with clang6 [1]
Use a different distfile that has a properly versioned directory. The checksum
has changed, but there are no file changes, only the WRKSRC has been renamed
from the confusing "libcoverart-{PROJECT_VERSION}" to "libcoverart-1.0.0".

Reported by:	pkg-fallout [1]
2018-01-20 23:06:41 +00:00

16 lines
529 B
C++

Fix build with clang6.
src/xmlParser.cpp:676:27: error: cast from pointer to smaller type 'char' loses information
lpszNew[cbData] = (XMLCHAR)NULL;
^~~~~~~~~~~~~
--- src/xmlParser.cpp.orig 2018-01-20 21:39:55 UTC
+++ src/xmlParser.cpp
@@ -673,7 +673,7 @@ XMLSTR stringDup(XMLCSTR lpszData, int cbData)
if (lpszNew)
{
memcpy(lpszNew, lpszData, (cbData) * sizeof(XMLCHAR));
- lpszNew[cbData] = (XMLCHAR)NULL;
+ lpszNew[cbData] = 0;
}
return lpszNew;
}