Avoid code duplication in SDL_GetPixelFormatDetails
This commit is contained in:
@@ -661,8 +661,7 @@ const SDL_PixelFormatDetails *SDL_GetPixelFormatDetails(SDL_PixelFormat format)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (SDL_FindInHashTable(SDL_format_details, (const void *)(uintptr_t)format, (const void **)&details)) {
|
if (SDL_FindInHashTable(SDL_format_details, (const void *)(uintptr_t)format, (const void **)&details)) {
|
||||||
SDL_UnlockMutex(SDL_format_details_lock);
|
goto done;
|
||||||
return details;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Allocate an empty pixel format structure, and initialize it */
|
/* Allocate an empty pixel format structure, and initialize it */
|
||||||
|
|||||||
Reference in New Issue
Block a user