Skip to content
Snippets Groups Projects
Unverified Commit bce23c24 authored by RadsammyT's avatar RadsammyT
Browse files

PR#3 review: fix -l arg breaking

because optarg goes NULL when encountering an optional argument, so I have to do this instead to get the argument. See case 'p'.
parent caa93cda
No related branches found
No related tags found
No related merge requests found
......@@ -263,7 +263,7 @@ int main(int argc, char** argv) {
break;
}
case 'l': {
std::string str_arg(optarg);
std::string str_arg(argv[optind++]);
str_arg.append(",0"); // FALLBACK: if string is partially completed ("1234,3")
// this will set all those unset to 0. otherwise we get
// all 3s.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment