diff options
| author | Matthew Sheby <44249925+msheby@users.noreply.github.com> | 2023-02-09 17:35:16 -0800 |
|---|---|---|
| committer | Matthew Sheby <44249925+msheby@users.noreply.github.com> | 2023-02-09 17:35:16 -0800 |
| commit | 78f8a623de5a03b361c6c7df8d6e85a67763e503 (patch) | |
| tree | 8f298762ffbb7227aa198ba54110418db9c0822d /src/asdcp-wrap.cpp | |
| parent | 3f9fd2c3c3fffcccd53016619475b32642ed6aa5 (diff) | |
feature: allow an MCA label to start with a hyphen
Diffstat (limited to 'src/asdcp-wrap.cpp')
| -rwxr-xr-x | src/asdcp-wrap.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/asdcp-wrap.cpp b/src/asdcp-wrap.cpp index 7715b77..fa75ede 100755 --- a/src/asdcp-wrap.cpp +++ b/src/asdcp-wrap.cpp @@ -105,6 +105,12 @@ public: return; \ } +#define TEST_EXTRA_ARG_ALLOW_DASH(i,c) \ + if ( ++i >= argc ) { \ + fprintf(stderr, "Argument not found for option -%c.\n", (c)); \ + return; \ + } + // static void @@ -443,7 +449,7 @@ public: case 'M': write_hmac = false; break; case 'm': - TEST_MCA_EXTRA_ARG(i, 'm'); + TEST_EXTRA_ARG_ALLOW_DASH(i, 'm'); mca_config_str = argv[i]; break; |
