Check for negative source rectangle in SDL_SoftBlit() (thanks John!)

This commit is contained in:
Sam Lantinga
2013-07-30 20:57:26 -07:00
parent 0f4de98390
commit 94c6b39a04

View File

@@ -61,7 +61,7 @@ SDL_SoftBlit(SDL_Surface * src, SDL_Rect * srcrect,
}
/* Set up source and destination buffer pointers, and BLIT! */
if (okay && srcrect->w && srcrect->h) {
if (okay && !SDL_RectEmpty(srcrect)) {
SDL_BlitFunc RunBlit;
SDL_BlitInfo *info = &src->map->info;