No real changes, just fix a warning in the test suite.

Don't assign wxNO_LEN to int variable, this results in gcc warnings about
overflow in implicit constant conversion.

Use size_t for the variable containing string length to fix it.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65838 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2010-10-17 13:59:55 +00:00
parent e3cd024e85
commit dbd92d3d0c

View File

@@ -54,7 +54,7 @@ private:
// //
// the length of the string may need to be passed explicitly if it has // the length of the string may need to be passed explicitly if it has
// embedded NULs, otherwise it's not necessary // embedded NULs, otherwise it's not necessary
void TestFirstChar(const char *src, wchar_t wch, int len = wxNO_LEN); void TestFirstChar(const char *src, wchar_t wch, size_t len = wxNO_LEN);
void Empty(); void Empty();
void Short(); void Short();
@@ -89,7 +89,7 @@ CPPUNIT_TEST_SUITE_NAMED_REGISTRATION(ConvAutoTestCase, "ConvAutoTestCase");
// tests // tests
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
void ConvAutoTestCase::TestFirstChar(const char *src, wchar_t wch, int len) void ConvAutoTestCase::TestFirstChar(const char *src, wchar_t wch, size_t len)
{ {
wxWCharBuffer wbuf = wxConvAuto().cMB2WC(src, len, NULL); wxWCharBuffer wbuf = wxConvAuto().cMB2WC(src, len, NULL);
CPPUNIT_ASSERT( wbuf ); CPPUNIT_ASSERT( wbuf );