Skip to content

Commit

Permalink
src: do not compare against wide characters
Browse files Browse the repository at this point in the history
PR-URL: #32921
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: David Carlier <devnexen@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
Reviewed-By: Zeyu Yang <himself65@outlook.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Juan José Arboleda <soyjuanarbol@gmail.com>
  • Loading branch information
bl-ue authored and targos committed May 13, 2020
1 parent 60db9af commit 08b66f2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/node_env_var.cc
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ void RealEnvStore::Set(Isolate* isolate,
node::Utf8Value val(isolate, value);

#ifdef _WIN32
if (key.length() > 0 && key[0] == L'=') return;
if (key.length() > 0 && key[0] == '=') return;
#endif
uv_os_setenv(*key, *val);
}
Expand All @@ -123,7 +123,7 @@ int32_t RealEnvStore::Query(const char* key) const {
}

#ifdef _WIN32
if (key[0] == L'=') {
if (key[0] == '=') {
return static_cast<int32_t>(v8::ReadOnly) |
static_cast<int32_t>(v8::DontDelete) |
static_cast<int32_t>(v8::DontEnum);
Expand Down

0 comments on commit 08b66f2

Please sign in to comment.