mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-10-17 07:16:00 +00:00
Pointer as bool (libsdl-org#7214)
This commit is contained in:
@@ -219,7 +219,7 @@ int SDL_SW_FillTriangle(SDL_Surface *dst, SDL_Point *d0, SDL_Point *d1, SDL_Poin
|
||||
|
||||
SDL_Surface *tmp = NULL;
|
||||
|
||||
if (dst == NULL) {
|
||||
if (!dst) {
|
||||
return -1;
|
||||
}
|
||||
|
||||
@@ -271,7 +271,7 @@ int SDL_SW_FillTriangle(SDL_Surface *dst, SDL_Point *d0, SDL_Point *d1, SDL_Poin
|
||||
|
||||
/* Use an intermediate surface */
|
||||
tmp = SDL_CreateSurface(dstrect.w, dstrect.h, format);
|
||||
if (tmp == NULL) {
|
||||
if (!tmp) {
|
||||
ret = -1;
|
||||
goto end;
|
||||
}
|
||||
@@ -459,7 +459,7 @@ int SDL_SW_BlitTriangle(
|
||||
|
||||
int has_modulation;
|
||||
|
||||
if (src == NULL || dst == NULL) {
|
||||
if (!src || !dst) {
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user