[Scummvm-cvs-logs] SF.net SVN: scummvm: [29161] scummvm/trunk/engines/parallaction/inventory. cpp
peres001 at users.sourceforge.net
peres001 at users.sourceforge.net
Sun Oct 7 09:11:11 CEST 2007
Revision: 29161
http://scummvm.svn.sourceforge.net/scummvm/?rev=29161&view=rev
Author: peres001
Date: 2007-10-07 00:11:09 -0700 (Sun, 07 Oct 2007)
Log Message:
-----------
Fixed bug #1808529. One must use memmove() when copying overlapping blocks of memory (blush).
Modified Paths:
--------------
scummvm/trunk/engines/parallaction/inventory.cpp
Modified: scummvm/trunk/engines/parallaction/inventory.cpp
===================================================================
--- scummvm/trunk/engines/parallaction/inventory.cpp 2007-10-07 00:35:22 UTC (rev 29160)
+++ scummvm/trunk/engines/parallaction/inventory.cpp 2007-10-07 07:11:09 UTC (rev 29161)
@@ -302,7 +302,7 @@
_numItems--;
if (_numItems != pos) {
- memcpy(&_items[pos], &_items[pos+1], (_numItems - pos) * sizeof(InventoryItem));
+ memmove(&_items[pos], &_items[pos+1], (_numItems - pos) * sizeof(InventoryItem));
}
_items[_numItems]._id = 0;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list