SDL_GetCameras() follows the SDL_GetStringRule

This commit is contained in:
Sam Lantinga committed 2024-07-19 12:22:03 -07:00
1 parent 0fe6603747
commit 01199469de
4 files changed
+12 -13

No files matched your search

+1 -3
View File
@@ -101,7 +101,7 @@ int SDL_AppInit(void **appstate, int argc, char *argv[])
return SDL_APP_FAILURE;
}
SDL_CameraID *devices = SDL_GetCameras(&devcount);
const SDL_CameraID *devices = SDL_GetCameras(&devcount);
if (!devices) {
SDL_Log("SDL_GetCameras failed: %s", SDL_GetError());
return SDL_APP_FAILURE;
@@ -140,8 +140,6 @@ int SDL_AppInit(void **appstate, int argc, char *argv[])
}
}
SDL_free(devices);
if (!camera_id) {
SDL_Log("No cameras available?");
return SDL_APP_FAILURE;