Skip to content
Snippets Groups Projects
  • Mike Hommey's avatar
    7c13c9404c2c
    changegroup: use a copy of hookargs when invoking the changegroup hook · 7c13c9404c2c
    Mike Hommey authored
    addchangegroup creates a runhook function that is used to invoke the
    changegroup and incoming hooks, but at the time the function is called,
    the contents of hookargs associated with the transaction may have been
    modified externally. For instance, bundle2 code affects it with
    obsolescence markers and bookmarks info.
    
    It also creates problems when a single transaction is used with multiple
    changegroups added (as per an upcoming change), whereby the contents
    of hookargs are that of after adding a latter changegroup when invoking
    the hook for the first changegroup.
    7c13c9404c2c
    History
    changegroup: use a copy of hookargs when invoking the changegroup hook
    Mike Hommey authored
    addchangegroup creates a runhook function that is used to invoke the
    changegroup and incoming hooks, but at the time the function is called,
    the contents of hookargs associated with the transaction may have been
    modified externally. For instance, bundle2 code affects it with
    obsolescence markers and bookmarks info.
    
    It also creates problems when a single transaction is used with multiple
    changegroups added (as per an upcoming change), whereby the contents
    of hookargs are that of after adding a latter changegroup when invoking
    the hook for the first changegroup.