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

Commit ee673e9d authored by Treehugger Robot's avatar Treehugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Add compile-time checks for libandroid_runtime" into main

parents ee03ff34 63e4e443
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -43,7 +43,10 @@ cc_library_shared_for_libandroid_runtime {

        "-Wall",
        "-Werror",
        "-Wextra",
        "-Wthread-safety",
        "-Wno-error=deprecated-declarations",
        "-Wno-unused-parameter",
        "-Wunused",
        "-Wunreachable-code",

+3 −3
Original line number Diff line number Diff line
@@ -44,7 +44,7 @@ static struct {

static int NativeGetTimers(JNIEnv* env, jobject /*clazz*/, jobjectArray timer, jboolean reset) {
  size_t size = ResourceTimer::counterSize;
  if (jsize st = env->GetArrayLength(timer); st < size) {
  if (size_t st = env->GetArrayLength(timer); st < size) {
      // Shrink the size to the minimum of the available counters and the available space.
      size = st;
  }
+2 −2
Original line number Diff line number Diff line
@@ -1892,8 +1892,8 @@ static sp<TiffWriter> DngCreator_setup(JNIEnv* env, jobject thiz, uint32_t image
        camera_metadata_entry entry =
            results.find(ANDROID_SENSOR_NOISE_PROFILE);

        const status_t numPlaneColors = isBayer ? 3 : 1;
        const status_t numCfaChannels = isBayer ? 4 : 1;
        const unsigned long numPlaneColors = isBayer ? 3 : 1;
        const unsigned long numCfaChannels = isBayer ? 4 : 1;

        uint8_t cfaOut[numCfaChannels];
        if ((err = convertCFA(cfaEnum, /*out*/cfaOut)) != OK) {
+1 −1
Original line number Diff line number Diff line
@@ -599,7 +599,7 @@ static jint CameraExtensionJpegProcessor_compressJpegFromYUV420p(
            quality, cropLeft, cropTop, cropRight, cropBottom, rot90);

    size_t finalJpegSize = actualJpegSize + sizeof(CameraBlob);
    if (finalJpegSize > outBufCapacity) {
    if (finalJpegSize > static_cast<size_t>(outBufCapacity)) {
        ALOGE("%s: Final jpeg buffer %zu not large enough for the jpeg blob header with "\
                "capacity %d", __FUNCTION__, finalJpegSize, outBufCapacity);
        return actualJpegSize;
+2 −2
Original line number Diff line number Diff line
@@ -88,12 +88,12 @@ static jint convertAudioProductStrategiesFromNative(
    int attrGroupIndex = 0;
    std::map<int /**attributesGroupIndex*/, std::vector<VolumeGroupAttributes> > groups;
    for (const auto &attr : strategy.getVolumeGroupAttributes()) {
        int groupId = attr.getGroupId();
        auto groupId = attr.getGroupId();
        int streamType = attr.getStreamType();
        const auto &iter = std::find_if(begin(groups), end(groups),
                                        [groupId, streamType](const auto &iter) {
            const auto &frontAttr = iter.second.front();
            return frontAttr.getGroupId() == groupId && frontAttr.getStreamType() == streamType;
            return (frontAttr.getGroupId() == groupId && frontAttr.getStreamType() == streamType);
        });
        // Same Volume Group Id and same stream type
        if (iter != end(groups)) {
Loading