Skip to content

Commit 029b50d

Browse files
danbevtargos
authored andcommitted
src: fix compiler warning in node_worker.cc
Currently, when configuring --without-ssl the following compiler warning is generated: ../src/node_worker.cc:192:10: warning: unused variable 'inspector_started' [-Wunused-variable] bool inspector_started = false; ^ 1 warning generated. This commit adds a macro guard to the variable to avoid the warning. PR-URL: #28198 Reviewed-By: Yongsheng Zhang <[email protected]> Reviewed-By: Richard Lau <[email protected]> Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: Rich Trott <[email protected]> Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: James M Snell <[email protected]>
1 parent 4eaac83 commit 029b50d

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/node_worker.cc

+2
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,9 @@ void Worker::Run() {
189189
Locker locker(isolate_);
190190
Isolate::Scope isolate_scope(isolate_);
191191
SealHandleScope outer_seal(isolate_);
192+
#if NODE_USE_V8_PLATFORM && HAVE_INSPECTOR
192193
bool inspector_started = false;
194+
#endif
193195

194196
DeleteFnPtr<Environment, FreeEnvironment> env_;
195197
OnScopeLeave cleanup_env([&]() {

0 commit comments

Comments
 (0)