* Parse "opt" or "opt= ", setting value respectively to either * NULL or the string after "=". */
| 598 | * NULL or the string after "=". |
| 599 | */ |
| 600 | static int opt_with_value(const char *arg, const char *opt, const char **value) |
| 601 | { |
| 602 | if (skip_prefix(arg, opt, &arg)) { |
| 603 | if (!*arg) { |
| 604 | *value = NULL; |
| 605 | return 1; |
| 606 | } |
| 607 | if (*arg++ == '=') { |
| 608 | *value = arg; |
| 609 | return 1; |
| 610 | } |
| 611 | } |
| 612 | return 0; |
| 613 | } |
| 614 | |
| 615 | static void handle_ref_opt(const char *pattern, const char *prefix) |
| 616 | { |