livoxGen1: Use RAII to close dlopen handle

This commit is contained in:
2025-11-01 01:54:49 -04:00
parent c2c6d409dd
commit 58e9b09995
+1 -5
View File
@@ -497,11 +497,7 @@ extern "C" int livoxGen1_finalizeInd(void)
(*livoxProto1.livoxProto1_exit)();
}
if (livoxProto1.dlopenHandle)
{
dlclose(livoxProto1.dlopenHandle.get());
livoxProto1.dlopenHandle.reset();
}
livoxProto1.dlopenHandle.reset(nullptr);
livoxProto1 = LivoxProto1DllState();
return 0; // Success