Skip to content

Commit

Permalink
fix: swallow unhandled exceptions on shutdown (#33)
Browse files Browse the repository at this point in the history
* fix: swallow unhandled exceptions on shutdown

* chore: bump version
  • Loading branch information
deepak1556 authored Oct 3, 2024
1 parent 8ac37eb commit 720f523
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 13 deletions.
16 changes: 6 additions & 10 deletions binding.gyp
Original file line number Diff line number Diff line change
Expand Up @@ -5,22 +5,21 @@
"sources": [
"src/main.cc"
],
"dependencies": [
"<!(node -p \"require('node-addon-api').targets\"):node_addon_api_except"
],
"include_dirs": [
"<!(node -p \"require('node-addon-api').include_dir\")"
],
'cflags!': ['-fno-exceptions'],
'cflags_cc!': ['-fno-exceptions'],
"defines": [ "NODE_API_SWALLOW_UNTHROWABLE_EXCEPTIONS" ],
'conditions': [
['OS=="mac"', {
"sources": [
"src/macos/PolicyWatcher.cc",
],
"defines": [
"MACOS",
],
"xcode_settings": {
"GCC_ENABLE_CPP_EXCEPTIONS": "YES"
}
]
}],
['OS=="mac" and target_arch=="arm64"', {
"xcode_settings": {
Expand All @@ -42,8 +41,7 @@
"src/windows/NumberPolicy.cc"
],
"defines": [
"WINDOWS",
"_HAS_EXCEPTIONS=1"
"WINDOWS"
],
"libraries": [
"userenv.lib"
Expand All @@ -53,10 +51,8 @@
},
"msvs_settings": {
"VCCLCompilerTool": {
"ExceptionHandling": 1,
'AdditionalOptions': [
'/guard:cf',
'-std:c++17',
'/we4244',
'/we4267',
'/ZH:SHA_256'
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vscode/policy-watcher",
"version": "1.1.7",
"version": "1.1.8",
"description": "",
"main": "index.js",
"repository": {
Expand Down

0 comments on commit 720f523

Please sign in to comment.