mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-09-17 08:48:12 +00:00
Fixed most small problems reported by cppcheck for src/core PR #7307 (from @kevin2kevin2)
This commit is contained in:
@@ -772,11 +772,10 @@ JNIEXPORT int JNICALL SDL_JAVA_INTERFACE(nativeRunMain)(JNIEnv *env, jclass cls,
|
||||
*/
|
||||
argv[argc++] = SDL_strdup("app_process");
|
||||
for (i = 0; i < len; ++i) {
|
||||
const char *utf;
|
||||
char *arg = NULL;
|
||||
jstring string = (*env)->GetObjectArrayElement(env, array, i);
|
||||
if (string) {
|
||||
utf = (*env)->GetStringUTFChars(env, string, 0);
|
||||
const char *utf = (*env)->GetStringUTFChars(env, string, 0);
|
||||
if (utf) {
|
||||
arg = SDL_strdup(utf);
|
||||
(*env)->ReleaseStringUTFChars(env, string, utf);
|
||||
@@ -1444,10 +1443,10 @@ SDL_bool Android_JNI_ShouldMinimizeOnFocusLoss()
|
||||
|
||||
SDL_bool Android_JNI_GetAccelerometerValues(float values[3])
|
||||
{
|
||||
int i;
|
||||
SDL_bool retval = SDL_FALSE;
|
||||
|
||||
if (bHasNewData) {
|
||||
int i;
|
||||
for (i = 0; i < 3; ++i) {
|
||||
values[i] = fLastAccelerometer[i];
|
||||
}
|
||||
|
Reference in New Issue
Block a user