[Scummvm-cvs-logs] scummvm master -> 857f146bcb585ddffba581eb9d7ad7c8f20e7f5f

whoozle whoozle at yandex.ru
Tue Jun 28 09:21:09 CEST 2011


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
857f146bcb DREAMWEB: Removed memcpy as suggested by wjp


Commit: 857f146bcb585ddffba581eb9d7ad7c8f20e7f5f
    https://github.com/scummvm/scummvm/commit/857f146bcb585ddffba581eb9d7ad7c8f20e7f5f
Author: Vladimir Menshakov (whoozle at yandex.ru)
Date: 2011-06-28T00:18:52-07:00

Commit Message:
DREAMWEB: Removed memcpy as suggested by wjp

Changed paths:
    engines/dreamweb/runtime.h



diff --git a/engines/dreamweb/runtime.h b/engines/dreamweb/runtime.h
index 2951ad8..a97ea2c 100644
--- a/engines/dreamweb/runtime.h
+++ b/engines/dreamweb/runtime.h
@@ -464,12 +464,9 @@ public:
 
 	inline void _movsb(uint size, bool clear_cx = false) {
 		assert(size != 0xffff);
-		uint8 *dst = es.ptr(di, size);
-		uint8 *src = ds.ptr(si, size);
-		assert(src < dst || src >= dst + size);
-		memcpy(dst, src, size);
-		di += size;
-		si += size;
+		//fixme: add overlap and segment boundary check and rewrite
+		while(size--)
+			_movsb();
 		if (clear_cx)
 			cx = 0;
 	}






More information about the Scummvm-git-logs mailing list