3 ms·
Typically, I would hope so. A good code review process should typically catch when it isn't done like this. In context, "typically" means your devops people g
by MaulingMonkey 11y ago
Typically, I would hope so. A good code review process should typically catch when it isn't done like this.
In context, "typically" means your devops people get to work on Christmas to patch a critical CVE being actively exploited in the wild pissing off all your customers that one time someone didn't do the typical pattern anywhere in your codebase or the codebases of any of your 3rd party libaries, frameworks, applications...
Where "didn't do the typical pattern" might be if conditions as shown, or forgetting the "case -1", or missed a key and typed "case 1", or elided the "break;" from the case above (I note no "break;"s in your switch ;)), or didn't rtfm closely enough to see -1 was a special exit code, or mis-assumed kill(-1,...) was a noop, or ...