builtin/apply: read_patch_file() return -1 instead of die()ing
authorChristian Couder <christian.couder@gmail.com>
Mon, 8 Aug 2016 21:03:01 +0000 (23:03 +0200)
committerJunio C Hamano <gitster@pobox.com>
Thu, 11 Aug 2016 19:41:46 +0000 (12:41 -0700)
commit3bee345d7b6c7d95e9585b224320689979a58f9e
treeea7236e8826bb0259f8018c3469e88ac91467d27
parentf07a9f7643c8b261b5d03d9c288c44916277f05e
builtin/apply: read_patch_file() return -1 instead of die()ing

To libify `git apply` functionality we have to signal errors to the
caller instead of die()ing. Let's do that by returning -1 instead of
die()ing in read_patch_file().

Helped-by: Stefan Beller <sbeller@google.com>
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/apply.c