Skip to content

Commit

Permalink
chore: Cleanup C++
Browse files Browse the repository at this point in the history
  • Loading branch information
mrousavy committed Apr 21, 2024
1 parent 6cdf1ef commit d575008
Showing 1 changed file with 1 addition and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -176,12 +176,7 @@ jsi::Value FrameHostObject::get(jsi::Runtime& runtime, const jsi::PropNameID& pr
if (result != 0) {
throw jsi::JSError(runtime, "Failed to lock HardwareBuffer for reading!");
}
finally([&]() {
int result = AHardwareBuffer_unlock(hardwareBuffer, nullptr);
if (result != 0) {
throw jsi::JSError(runtime, "Failed to lock HardwareBuffer for reading!");
}
});
finally([&]() { AHardwareBuffer_unlock(hardwareBuffer, nullptr); });

// directly write to C++ JSI ArrayBuffer
auto destinationBuffer = arrayBuffer.data(runtime);
Expand Down

0 comments on commit d575008

Please sign in to comment.