diff options
Diffstat (limited to 'libdeno/snapshot_creator.cc')
-rw-r--r-- | libdeno/snapshot_creator.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libdeno/snapshot_creator.cc b/libdeno/snapshot_creator.cc index d38b6c075..ceafe0fd7 100644 --- a/libdeno/snapshot_creator.cc +++ b/libdeno/snapshot_creator.cc @@ -26,8 +26,8 @@ int main(int argc, char** argv) { deno_config config = {1, deno::empty_buf, deno::empty_buf, nullptr}; Deno* d = deno_new(config); - int r = deno_execute(d, nullptr, js_fn, js_source.c_str()); - if (!r) { + deno_execute(d, nullptr, js_fn, js_source.c_str()); + if (deno_last_exception(d) != nullptr) { std::cerr << "Snapshot Exception " << std::endl; std::cerr << deno_last_exception(d) << std::endl; deno_delete(d); |