Skip to content
  • Simon Glass's avatar
    patman: Only apply patches when we know the original HEAD · 4251978a
    Simon Glass authored
    
    
    When patman applies the patches it checks out a new branch, uses 'git am'
    to apply the patches one by one, and then tries to go back to the old
    branch. If you try this when the branch is 'undefined', this doesn't work
    as patman cannot restore the correct branch after applying the patches.
    It seems that 'undefined' is created by git and is persistent after it is
    created, so that you can end up on quite an old branch.
    
    Add a check for the 'undefined' branch to avoid this.
    
    Reported-by: default avatarMasahiro Yamada <yamada.m@jp.panasonic.com>
    Signed-off-by: default avatarSimon Glass <sjg@chromium.org>
    4251978a