commit | 5ed5f671c4193f2b9d47c08e989574903f3bf9cc | [log] [tgz] |
---|---|---|
author | Jeff King <peff@peff.net> | Sun Jan 31 06:26:16 2016 -0500 |
committer | Junio C Hamano <gitster@pobox.com> | Mon Feb 01 13:43:30 2016 -0800 |
tree | 2447fafcbb557c51b191fde384c5ea202327eb92 | |
parent | 9096ee162b7e4e426b1719bb43f9e42e84c95816 [diff] |
checkout-index: handle "--no-prefix" option We use a custom callback to parse "--prefix", but it does not handle the "unset" case. As a result, passing "--no-prefix" will cause a segfault. We can fix this by switching it to an OPT_STRING, which makes "--no-prefix" counteract a previous "--prefix". Note that this assigns NULL, so we bump our default-case initialization to lower in the main function. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>