From 120f9686a95ce1237f9fe2d18396c53b5c1f0c5b Mon Sep 17 00:00:00 2001 From: Raymond Zhao <7199958+rzhao271@users.noreply.github.com> Date: Wed, 21 Jan 2026 16:39:57 -0800 Subject: [PATCH 1/3] chore: add stack-protector-strong flag --- binding.gyp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/binding.gyp b/binding.gyp index c6d41025..13ecb1d2 100644 --- a/binding.gyp +++ b/binding.gyp @@ -60,7 +60,7 @@ 'libraries': [ '-lutil' ], - 'cflags': ['-Wall', '-O2'], + 'cflags': ['-Wall', '-O2', '-fstack-protector-strong'], 'ldflags': [], 'conditions': [ # http://www.gnu.org/software/gnulib/manual/html_node/forkpty.html From ece5c77dd2d1f110b72d2bd2fce999e92a7e5b74 Mon Sep 17 00:00:00 2001 From: Raymond Zhao <7199958+rzhao271@users.noreply.github.com> Date: Wed, 21 Jan 2026 16:58:14 -0800 Subject: [PATCH 2/3] chore: move up cflags --- binding.gyp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/binding.gyp b/binding.gyp index 13ecb1d2..038f17cc 100644 --- a/binding.gyp +++ b/binding.gyp @@ -27,6 +27,8 @@ ] } }, + }, { + 'cflags': ['-O2', '-fstack-protector-strong'], }], ], }, @@ -60,7 +62,7 @@ 'libraries': [ '-lutil' ], - 'cflags': ['-Wall', '-O2', '-fstack-protector-strong'], + 'cflags': ['-Wall'], 'ldflags': [], 'conditions': [ # http://www.gnu.org/software/gnulib/manual/html_node/forkpty.html From 1472d8ac5738d0d0e1f94cc415f379b37e798a84 Mon Sep 17 00:00:00 2001 From: Raymond Zhao <7199958+rzhao271@users.noreply.github.com> Date: Thu, 22 Jan 2026 11:06:36 -0800 Subject: [PATCH 3/3] fix inconsistent indentation --- binding.gyp | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/binding.gyp b/binding.gyp index 038f17cc..9e8780ea 100644 --- a/binding.gyp +++ b/binding.gyp @@ -9,24 +9,24 @@ 'SpectreMitigation': 'Spectre' }, 'msvs_settings': { - 'VCCLCompilerTool': { - 'AdditionalOptions': [ - '/guard:cf', - '/sdl', - '/W3', - '/we4146', - '/we4244', - '/we4267', - '/ZH:SHA_256' - ] - }, - 'VCLinkerTool': { - 'AdditionalOptions': [ - '/DYNAMICBASE', - '/guard:cf' - ] - } + 'VCCLCompilerTool': { + 'AdditionalOptions': [ + '/guard:cf', + '/sdl', + '/W3', + '/we4146', + '/we4244', + '/we4267', + '/ZH:SHA_256' + ] }, + 'VCLinkerTool': { + 'AdditionalOptions': [ + '/DYNAMICBASE', + '/guard:cf' + ] + } + }, }, { 'cflags': ['-O2', '-fstack-protector-strong'], }],