Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a87638c7 authored by Courtney Goeltzenleuchter's avatar Courtney Goeltzenleuchter Committed by Android (Google) Code Review
Browse files

Merge "Must return after throwing exception"

parents 9b87f289 9e82c386
Loading
Loading
Loading
Loading
+13 −1
Original line number Diff line number Diff line
@@ -107,6 +107,7 @@ fromEGLHandle(JNIEnv *_env, jmethodID mid, jobject obj) {
    if (obj == NULL){
        jniThrowException(_env, "java/lang/IllegalArgumentException",
                          "Object is set to null.");
        return nullptr;
    }

    jlong handle = _env->CallLongMethod(obj, mid);
@@ -238,6 +239,7 @@ exit:
    }
    if (_exception) {
        jniThrowException(_env, _exceptionType, _exceptionMessage);
        return false;
    }
    return (jboolean)_returnValue;
}
@@ -335,6 +337,7 @@ exit:
    }
    if (_exception) {
        jniThrowException(_env, _exceptionType, _exceptionMessage);
        return false;
    }
    return (jboolean)_returnValue;
}
@@ -454,6 +457,7 @@ exit:
    }
    if (_exception) {
        jniThrowException(_env, _exceptionType, _exceptionMessage);
        return false;
    }
    return (jboolean)_returnValue;
}
@@ -509,6 +513,7 @@ exit:
    }
    if (_exception) {
        jniThrowException(_env, _exceptionType, _exceptionMessage);
        return false;
    }
    return (jboolean)_returnValue;
}
@@ -582,6 +587,7 @@ exit:
    }
    if (_exception) {
        jniThrowException(_env, _exceptionType, _exceptionMessage);
        return nullptr;
    }
    return toEGLHandle(_env, eglsurfaceClass, eglsurfaceConstructor, _returnValue);
}
@@ -664,6 +670,7 @@ exit:
    }
    if (_exception) {
        jniThrowException(_env, _exceptionType, _exceptionMessage);
        return nullptr;
    }
    return toEGLHandle(_env, eglsurfaceClass, eglsurfaceConstructor, _returnValue);
}
@@ -721,6 +728,7 @@ exit:
    }
    if (_exception) {
        jniThrowException(_env, _exceptionType, _exceptionMessage);
        return nullptr;
    }
    return toEGLHandle(_env, eglsurfaceClass, eglsurfaceConstructor, _returnValue);
}
@@ -731,7 +739,7 @@ android_eglCreatePixmapSurface
  (JNIEnv *_env, jobject _this, jobject dpy, jobject config, jint pixmap, jintArray attrib_list_ref, jint offset) {
    jniThrowException(_env, "java/lang/UnsupportedOperationException",
        "eglCreatePixmapSurface");
    return toEGLHandle(_env, eglsurfaceClass, eglsurfaceConstructor, (EGLSurface) 0);
    return nullptr;
}

/* EGLBoolean eglDestroySurface ( EGLDisplay dpy, EGLSurface surface ) */
@@ -800,6 +808,7 @@ exit:
    }
    if (_exception) {
        jniThrowException(_env, _exceptionType, _exceptionMessage);
        return false;
    }
    return (jboolean)_returnValue;
}
@@ -898,6 +907,7 @@ exit:
    }
    if (_exception) {
        jniThrowException(_env, _exceptionType, _exceptionMessage);
        return nullptr;
    }
    return toEGLHandle(_env, eglsurfaceClass, eglsurfaceConstructor, _returnValue);
}
@@ -1034,6 +1044,7 @@ exit:
    }
    if (_exception) {
        jniThrowException(_env, _exceptionType, _exceptionMessage);
        return nullptr;
    }
    return toEGLHandle(_env, eglcontextClass, eglcontextConstructor, _returnValue);
}
@@ -1152,6 +1163,7 @@ exit:
    }
    if (_exception) {
        jniThrowException(_env, _exceptionType, _exceptionMessage);
        return false;
    }
    return (jboolean)_returnValue;
}