Docs say "The client's options are passed directly to its dr_client_main() initialization routine, in the same manner as arguments are passed to a regular application's main() routine". The C standard says that argv must be NULL terminated, but DR fails to set this up, so option parsers that rely on this will crash.
Looks like the fix is in parse_option_array. The free in free_option_array will also need changing.
Docs say "The client's options are passed directly to its dr_client_main() initialization routine, in the same manner as arguments are passed to a regular application's main() routine". The C standard says that argv must be NULL terminated, but DR fails to set this up, so option parsers that rely on this will crash.
Looks like the fix is in parse_option_array. The free in free_option_array will also need changing.