6 Feb
2012
6 Feb
'12
5:18 p.m.
The current implementation includes a check on param->bytes >= bytes specifically: if (data && param->bytes >= bytes) { ... } So if bytes<param->bytes returns D3DERR_INVALIDCALL. However, the MS version does not act that way: If the parameter is shorter than the length of the data, then the data that fits in the parameter is put and returns D3D_OK Therefore, the check of the size should be eliminated and in memcpy instead of referring to bytes, it should refer to min(bytes, param->bytes) Luis