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

Commit ee821931 authored by qctecmdr's avatar qctecmdr Committed by Gerrit - the friendly Code Review server
Browse files

Merge "audio-HAL: Fix for KW static analysis issues"

parents 0586bad8 1bf8152a
Loading
Loading
Loading
Loading
+7 −3
Original line number Diff line number Diff line
@@ -30,7 +30,7 @@
/*
* Changes from Qualcomm Innovation Center are provided under the following license:
*
* Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
* Copyright (c) 2022-2023 Qualcomm Innovation Center, Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted (subject to the limitations in the
@@ -1370,8 +1370,10 @@ static void* spkr_calibration_thread()
                        }
                       thermal_fd = open(wsa_path, O_RDONLY);
                       if (thermal_fd > 0) {
                           if ((ret = read(thermal_fd, buf, sizeof(buf))) >= 0)
                           if ((ret = read(thermal_fd, buf, sizeof(buf))) >= 0) {
                               buf[ret-1] = '\0';
                               t0_spk_1 = atoi(buf);
                           }
                           else
                               ALOGE("%s: read fail for %s err:%d\n",
                                     __func__, wsa_path, ret);
@@ -1404,8 +1406,10 @@ static void* spkr_calibration_thread()
                        }
                        thermal_fd = open(wsa_path, O_RDONLY);
                        if (thermal_fd > 0) {
                           if ((ret = read(thermal_fd, buf, sizeof(buf))) >= 0)
                           if ((ret = read(thermal_fd, buf, sizeof(buf))) >= 0) {
                               buf[ret-1] = '\0';
                               t0_spk_2 = atoi(buf);
                           }
                           else
                               ALOGE("%s: read fail for %s err:%d\n",
                                     __func__, wsa_path, ret);