Skip to content
Snippets Groups Projects
Select Git revision
  • main
  • master default
  • 7.0.0.202409031743-jpms
  • 7.0.0-jpms-1
4 results

jgit

  • Clone with SSH
  • Clone with HTTPS
  • user avatar
    Matthias Sohn authored
    Fetch with protocol V2 failed under the following conditions
    - fetch uses bidirectional protocol (git, ssh) which uses a shortcut
      to determine invalid wants
    - not all wants are advertised
    - race condition: wanted ref is updated during fetch by another thread
      after the thread serving upload-pack determined wants and before it
      checks not advertised wants
    
    Fix this by calling
    `new ReachableCommitRequestValidator().checkWants(up, wants)`
    instead of throwing WantNotValidException in [1]
    if this race happened in the same way like it's done for unidirectional
    protocols (http) [2].
    
    [1] https://github.com/eclipse-jgit/jgit/blob/stable-6.10/org.eclipse.jgit/src/org/eclipse/jgit/transport/UploadPack.java#L2002
    [2] https://github.com/eclipse-jgit/jgit/blob/stable-6.10/org.eclipse.jgit/src/org/eclipse/jgit/transport/UploadPack.java#L2000
    
    Bug: jgit-48
    Change-Id: I32f28502923815dc49781aab5d810c9afbe7e7e6
    56a5db65
    History
    Name Last commit Last update