Skip to content

git_cherrypick() leaving behind CHERRY_PICK_HEAD on success #7124

@MichalMaruska

Description

@MichalMaruska

Looking at this code:

cherrypick_state_cleanup(repo);

.... it seems that cherrypick_state_cleanup() should be invoked on success, not on error, hence:

+	cherrypick_state_cleanup(repo);   /// MUST do it here
	goto done;

on_error:
-       // cherrypick_state_cleanup(repo);    // here it's inverted!, so drop it
done:
	git_indexwriter_cleanup(&indexwriter);
        ....

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions