someone should have tested it with the __WCLONE option at least once to see if it returned -EINVAL
was it caught by unit testing? if not, it should have been
could have been sloppy code. that wouldn’t surprise me. better hacks involve pts to functions buried in hex tables of object code
No need to unit test two lines when you know what those two lines are and can read the code.
“could have been sloppy code. that wouldnt surprise me. better hacks involve pts to functions buried in hex tables of object code”
Yeah, but I think that’s exactly what makes this a good hack, in a way. It COULD just be sloppy code. And sloppy code can slip past a lot of eyes, sometimes.
someone should have tested it with the __WCLONE option at least once to see if it returned -EINVAL
if ((options == (__WCLONE|__WALL))
Whether this itself makes sense (i.e. to only take the conditional if both
flags are set) or it this would tend to be something with some more
devious intent - I don’t have enough knowledge to say.