| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 3666662 commit c3c5141
3 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -420,11 +420,11 @@ inline void Environment::set_trace_sync_io(bool value) { | |||
| 420 | 420 | } | |
| 421 | 421 | ||
| 422 | 422 | inline bool Environment::abort_on_uncaught_exception() const { | |
| 423 | - return abort_on_uncaught_exception_; | ||
| 423 | + return options_->abort_on_uncaught_exception; | ||
| 424 | 424 | } | |
| 425 | 425 | ||
| 426 | 426 | inline void Environment::set_abort_on_uncaught_exception(bool value) { | |
| 427 | - abort_on_uncaught_exception_ = value; | ||
| 427 | + options_->abort_on_uncaught_exception = value; | ||
| 428 | 428 | } | |
| 429 | 429 | ||
| 430 | 430 | inline AliasedBuffer<uint32_t, v8::Uint32Array>& | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -183,9 +183,6 @@ static node_module* modlist_internal; | |||
| 183 | 183 | static node_module* modlist_linked; | |
| 184 | 184 | static node_module* modlist_addon; | |
| 185 | 185 | ||
| 186 | - // TODO(addaleax): This should not be global. | ||
| 187 | - static bool abort_on_uncaught_exception = false; | ||
| 188 | - | ||
| 189 | 186 | // Bit flag used to track security reverts (see node_revert.h) | |
| 190 | 187 | unsigned int reverted = 0; | |
| 191 | 188 | ||
@@ -2669,7 +2666,7 @@ void ProcessArgv(std::vector<std::string>* args, | |||
| 2669 | 2666 | "--abort-on-uncaught-exception") != v8_args.end() || | |
| 2670 | 2667 | std::find(v8_args.begin(), v8_args.end(), | |
| 2671 | 2668 | "--abort_on_uncaught_exception") != v8_args.end()) { | |
| 2672 | - abort_on_uncaught_exception = true; | ||
| 2669 | + env_opts->abort_on_uncaught_exception = true; | ||
| 2673 | 2670 | } | |
| 2674 | 2671 | ||
| 2675 | 2672 | // TODO(bnoordhuis) Intercept --prof arguments and start the CPU profiler | |
@@ -3044,8 +3041,6 @@ inline int Start(Isolate* isolate, IsolateData* isolate_data, | |||
| 3044 | 3041 | return 12; // Signal internal error. | |
| 3045 | 3042 | } | |
| 3046 | 3043 | ||
| 3047 | - env.set_abort_on_uncaught_exception(abort_on_uncaught_exception); | ||
| 3048 | - | ||
| 3049 | 3044 | // TODO(addaleax): Maybe access this option directly instead of setting | |
| 3050 | 3045 | // a boolean member of Environment. Ditto below for trace_sync_io. | |
| 3051 | 3046 | if (env.options()->no_force_async_hooks_checks) { | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -60,6 +60,7 @@ class DebugOptions { | |||
| 60 | 60 | class EnvironmentOptions { | |
| 61 | 61 | public: | |
| 62 | 62 | std::shared_ptr<DebugOptions> debug_options { new DebugOptions() }; | |
| 63 | + bool abort_on_uncaught_exception = false; | ||
| 63 | 64 | bool experimental_modules = false; | |
| 64 | 65 | bool experimental_repl_await = false; | |
| 65 | 66 | bool experimental_vm_modules = false; | |
| Back | FazBrowse Home | New Git URL |
0 commit comments