Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
optarg is not reset in musl's getopt and it leaks values to other flags. Reset it for all systems because it cannot hurt. If you remove the optarg reset, you should see the bug in action on alpine systems in DstubControllerTest.commandLineArgs when parsing argv2: ``` [ RUN ] DStubControllerTest.commandLineArgs d_controller_unittests.cc:102: Failure Expected equality of these values: std::string(ex.what()) Which is: "unsupported option: -b cfgName" "unsupported option: -b" [ FAILED ] DStubControllerTest.commandLineArgs (14 ms) ```
- Loading branch information