We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
pop_instance
1 parent cce5151 commit 2a1b554Copy full SHA for 2a1b554
src/DaedalusVm.cc
@@ -156,12 +156,16 @@ ZkDaedalusInstance* ZkDaedalusVm_popInstance(ZkDaedalusVm* slf) {
156
ZKC_TRACE_FN();
157
ZKC_CHECK_NULL(slf);
158
159
- auto instance = slf->handle.pop_instance();
160
- if (instance == nullptr) {
161
- return nullptr;
162
- }
163
-
164
- ZKC_RETURN_CATCH(new ZkDaedalusInstance(instance));
+ try {
+ auto instance = slf->handle.pop_instance();
+ if (instance == nullptr) {
+ return nullptr;
+ }
+ ZKC_RETURN_CATCH(new ZkDaedalusInstance(instance));
165
+ } catch (zenkit::DaedalusScriptError const& e) {
166
+ ZKC_LOG_ERROR("Failed to pop instance: %s", e.what());
167
168
169
}
170
171
ZkDaedalusInstance* ZkDaedalusVm_getGlobalSelf(ZkDaedalusVm* slf) {
0 commit comments