mirror of https://github.com/go-gitea/gitea.git
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
270c7f36db
Backport #17034 The rollback functionality in services/repository/repository.go:ForkRepository is incorrect and could lead to a deadlock as it uses DeleteRepository to delete the rolled-back repository - a function which creates its own transaction. This PR adjusts the rollback function to only use RemoveAll as any database changes will be automatically rolled-back. It also handles panics and adjusts the Close within WithTx to ensure that if there is a panic the session will always be closed. Signed-off-by: Andrew Thornton <art27@cantab.net> Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> |
3 years ago | |
---|---|---|
.. | ||
adopt.go | 4 years ago | |
archive.go | 4 years ago | |
branch.go | 4 years ago | |
cache.go | 4 years ago | |
check.go | 4 years ago | |
commits.go | 3 years ago | |
commits_test.go | 4 years ago | |
create.go | 4 years ago | |
create_test.go | 4 years ago | |
fork.go | 3 years ago | |
fork_test.go | 5 years ago | |
generate.go | 4 years ago | |
hooks.go | 4 years ago | |
init.go | 4 years ago | |
main_test.go | 5 years ago | |
push.go | 4 years ago | |
repo.go | 4 years ago | |
update.go | 5 years ago |