diff: only untrack notify payload when it is set
This commit is contained in:
parent
c43afaf9c4
commit
e8531dd5c3
2
diff.go
2
diff.go
|
@ -561,9 +561,11 @@ func freeDiffOptions(copts *C.git_diff_options) {
|
|||
freeStrarray(&cpathspec)
|
||||
C.free(unsafe.Pointer(copts.old_prefix))
|
||||
C.free(unsafe.Pointer(copts.new_prefix))
|
||||
if copts.notify_payload != nil {
|
||||
pointerHandles.Untrack(copts.notify_payload)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func (v *Repository) DiffTreeToTree(oldTree, newTree *Tree, opts *DiffOptions) (*Diff, error) {
|
||||
var diffPtr *C.git_diff
|
||||
|
|
Loading…
Reference in New Issue