src/saveload.cpp
branchnoai
changeset 10513 33cb70ff2f5d
parent 10455 22c441f5adf9
child 10645 8cbdb511a674
--- a/src/saveload.cpp	Wed May 07 21:09:51 2008 +0000
+++ b/src/saveload.cpp	Sun May 11 20:09:34 2008 +0000
@@ -531,7 +531,7 @@
 static inline size_t SlCalcNetStringLen(const char *ptr, size_t length)
 {
 	if (ptr == NULL) return 0;
-	return minu(strlen(ptr), length - 1);
+	return min(strlen(ptr), length - 1);
 }
 
 /** Calculate the gross length of the string that it
@@ -911,7 +911,7 @@
 static void SlLoadChunk(const ChunkHandler *ch)
 {
 	byte m = SlReadByte();
-	size_t len;
+	uint32 len;
 	uint32 endoffs;
 
 	_sl.block_mode = m;
@@ -1204,9 +1204,9 @@
 	_z.avail_out = 4096;
 
 	do {
-		/* read more bytes from the file?*/
+		/* read more bytes from the file? */
 		if (_z.avail_in == 0) {
-			_z.avail_in = fread(_z.next_in = _sl.buf + 4096, 1, 4096, _sl.fh);
+			_z.avail_in = (uint)fread(_z.next_in = _sl.buf + 4096, 1, 4096, _sl.fh);
 		}
 
 		/* inflate the data */
@@ -1493,7 +1493,7 @@
 	_fast_forward = 0;
 	if (_cursor.sprite == SPR_CURSOR_MOUSE) SetMouseCursor(SPR_CURSOR_ZZZ, PAL_NONE);
 
-	SendWindowMessage(WC_STATUS_BAR, 0, true, 0, 0);
+	InvalidateWindowData(WC_STATUS_BAR, 0, true);
 	_ts.saveinprogress = true;
 }
 
@@ -1504,7 +1504,7 @@
 	_fast_forward = _ts.ff_state;
 	if (_cursor.sprite == SPR_CURSOR_ZZZ) SetMouseCursor(SPR_CURSOR_MOUSE, PAL_NONE);
 
-	SendWindowMessage(WC_STATUS_BAR, 0, false, 0, 0);
+	InvalidateWindowData(WC_STATUS_BAR, 0, false);
 	_ts.saveinprogress = false;
 }