Using memcpy with clearly overlapping blocks is sad.

git-svn-id: https://svn.eduke32.com/eduke32@1407 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
plagman 2009-06-06 14:22:17 +00:00
parent 2186154dac
commit f46e3b44f4

View file

@ -4277,7 +4277,7 @@ static void polymer_addplanelight(_prplane* plane, int16_t lighti)
i++; i++;
} }
memcpy(&plane->lights[i+1], &plane->lights[i], sizeof(int16_t) * (PR_MAXLIGHTS - (i+1))); memmove(&plane->lights[i+1], &plane->lights[i], sizeof(int16_t) * (PR_MAXLIGHTS - (i+1)));
plane->lights[i] = lighti; plane->lights[i] = lighti;
plane->lightcount++; plane->lightcount++;