From 35009ebff741086291b547dcffefa6925ecc131c Mon Sep 17 00:00:00 2001 From: Max Horn Date: Sun, 18 Feb 2007 15:40:59 +0000 Subject: Const correctness svn-id: r25688 --- backends/saves/compressed/compressed-saves.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/backends/saves/compressed/compressed-saves.cpp b/backends/saves/compressed/compressed-saves.cpp index 431caf2a08..183e8dd355 100644 --- a/backends/saves/compressed/compressed-saves.cpp +++ b/backends/saves/compressed/compressed-saves.cpp @@ -244,7 +244,9 @@ public: return 0; // Hook in the new data ... - _stream.next_in = (Bytef*)dataPtr; + // Note: We need to make a const_cast here, as zlib is not aware + // of the const keyword. + _stream.next_in = const_cast((const byte *)dataPtr); _stream.avail_in = dataSize; // ... and flush it to disk -- cgit v1.2.3