Skip to content

Commit

Permalink
src: remove unprofessional slang in assertions
Browse files Browse the repository at this point in the history
Convert `CHECK(0 && "wtf?")` (sic) assertions to more suitable
`UNREACHABLE()` macro invocations in `node_zlib.cc`.

PR-URL: #17166
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Timothy Gu <timothygu99@gmail.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
  • Loading branch information
aqrln authored and gibfahn committed Dec 20, 2017
1 parent 3fe7f9f commit f26b576
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/node_zlib.cc
Original file line number Diff line number Diff line change
Expand Up @@ -336,7 +336,7 @@ class ZCtx : public AsyncWrap {
}
break;
default:
CHECK(0 && "wtf?");
UNREACHABLE();
}

// pass any errors back to the main thread to deal with.
Expand Down Expand Up @@ -547,7 +547,7 @@ class ZCtx : public AsyncWrap {
->AdjustAmountOfExternalAllocatedMemory(kInflateContextSize);
break;
default:
CHECK(0 && "wtf?");
UNREACHABLE();
}

ctx->dictionary_ = reinterpret_cast<Bytef *>(dictionary);
Expand Down

0 comments on commit f26b576

Please sign in to comment.