From c4e29afeaf94033b637fb6b2392e03d788fe1439 Mon Sep 17 00:00:00 2001 From: LuridHound <43679683+LuridHound@users.noreply.github.com> Date: Sun, 23 Nov 2025 03:08:17 +0300 Subject: [PATCH] Fix issue 1000 (#1040) * fix compilation warnings produced by -Wold-style-cast * remove incorrect cast --- tinyxml2.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tinyxml2.cpp b/tinyxml2.cpp index 97f64ae..50e6e2a 100644 --- a/tinyxml2.cpp +++ b/tinyxml2.cpp @@ -2656,7 +2656,7 @@ void XMLPrinter::Write( const char* data, size_t size ) fwrite ( data , sizeof(char), size, _fp); } else { - char* p = _buffer.PushArr( static_cast(size) ) - 1; // back up over the null terminator. + char* p = _buffer.PushArr( size ) - 1; // back up over the null terminator. memcpy( p, data, size ); p[size] = 0; }