gdd: make put() write full array if requested size=0

This commit is contained in:
Ralph Lange
2016-10-19 11:57:13 +02:00
parent 92ffe1d726
commit 5d5cc1029e

View File

@@ -1355,11 +1355,14 @@ gddStatus gdd::put ( const gdd * dd )
}
aitUint32 srcAvailSize = srcElemCount - unusedSrcBelow;
if ( srcAvailSize > this->getBounds()->size() ) {
srcCopySize = this->getBounds()->size();
}
else {
srcCopySize = srcAvailSize;
{
aitUint32 destSize = this->getBounds()->size();
if ( destSize > 0 && srcAvailSize > destSize ) {
srcCopySize = destSize;
}
else {
srcCopySize = srcAvailSize;
}
}
if ( dataVoid() == NULL )