libcore/.../rg_apache_harmony_xml_ExpatParser: in C++, the return type
of strchr(const char*) is 'const char*' instead of 'char *'.
C++ overloads string functions so that strchr(char*) returns 'char*' and
strchr(const char*) returns 'const char*'. This patch fixes an "invalid
conversion from ‘const char*’ to ‘char*’" error when building with gcc-4.4.
diff --git a/libcore/xml/src/main/native/org_apache_harmony_xml_ExpatParser.cpp b/libcore/xml/src/main/native/org_apache_harmony_xml_ExpatParser.cpp
index 7149272..40a4116 100644
--- a/libcore/xml/src/main/native/org_apache_harmony_xml_ExpatParser.cpp
+++ b/libcore/xml/src/main/native/org_apache_harmony_xml_ExpatParser.cpp
@@ -479,7 +479,7 @@
* @returns index of the separator
*/
static int findSeparator(const char* s) {
- char* pointer = strchr(s, '|');
+ const char* pointer = strchr(s, '|');
return pointer == NULL ? -1 : pointer - s;
}