patch_parse: handle absence of "index" header for new/deleted cases
This follows up on 11de594f which added support for parsing patches without extended headers (the "index <hash>..<hash> <mode>" line); issue #5267. We now allow transition from "file mode" state to "path" state directly if there is no "index", which will happen for patches adding or deleting files as demonstrated in added test case.
Showing
Please
register
or
sign in
to comment