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.
gitea/modules
zeripath 39a0db6ecf
Prevent dangling archiver goroutine (#19516) (#19526)
Backport #19516

Within doArchive there is a service goroutine that performs the
archiving function.  This goroutine reports its error using a `chan
error` called `done`. Prior to this PR this channel had 0 capacity
meaning that the goroutine would block until the `done` channel was
cleared - however there are a couple of ways in which this channel might
not be read.

The simplest solution is to add a single space of capacity to the
goroutine which will mean that the goroutine will always complete and
even if the `done` channel is not read it will be simply garbage
collected away.

(The PR also contains two other places when setting up the indexers
which do not leak but where the blocking of the sending goroutine is
also unnecessary and so we should just add a small amount of capacity
and let the sending goroutine complete as soon as it can.)

Signed-off-by: Andrew Thornton <art27@cantab.net>

Co-authored-by: 6543 <6543@obermui.de>

Co-authored-by: 6543 <6543@obermui.de>
3 years ago
..
activitypub Create pub/priv keypair for federation (#17071) 3 years ago
analyze Use git attributes to determine generated and vendored status for language stats and diffs (#16773) 3 years ago
appstate Decouple unit test code from business code (#17623) 3 years ago
auth fix pam authorization (#19040) (#19047) 3 years ago
avatar Fix various typos (#18219) 3 years ago
base Simplify parameter types (#18006) 3 years ago
cache Test cache during init (#17852) 3 years ago
charset Don't treat BOM escape sequence as hidden character. (#18909) (#18910) 3 years ago
context RepoAssignment ensure to close before overwrite (#19449) (#19460) 3 years ago
convert Set correct PR status on 3way on conflict checking (#19457) (#19458) 3 years ago
csv Fix various typos (#18219) 3 years ago
doctor [doctor] authorized-keys: fix displayed check name (backport #19464) (#19484) 3 years ago
emoji Run processors on whole of text (#16155) 4 years ago
eventsource Simplify parameter types (#18006) 3 years ago
generate Support webauthn (#17957) 3 years ago
git Prevent dangling cat-file calls (goroutine alternative) (#19454) (#19466) 3 years ago
gitgraph Collaborator trust model should trust collaborators (#18539) (#18557) 3 years ago
graceful Immediately Hammer if second kill is sent (#18823) (#18826) 3 years ago
hcaptcha hCaptcha Support (#12594) 4 years ago
highlight Bump to build with go1.18 (#19120 et al) (#19127) 3 years ago
hostmatcher Revert the minimal golang version requirement from 1.17 to 1.16 and add a warning in Makefile (#19319) 3 years ago
httpcache Use a variable but a function for IsProd because of a slight performance increment (#17368) 3 years ago
httplib refactor: move from io/ioutil to io and os package (#17109) 3 years ago
indexer Prevent dangling archiver goroutine (#19516) (#19526) 3 years ago
json Move repository model into models/repo (#17933) 3 years ago
lfs Improve SyncMirrors logging (#19045) (#19050) 3 years ago
log Simplify parameter types (#18006) 3 years ago
markup Bump goldmark to v1.4.11 (#19201) (#19203) 3 years ago
metrics Refactor auth package (#17962) 3 years ago
migration Fix various typos (#18219) 3 years ago
nosql Adjust error for already locked db and prevent level db lock on malformed connstr (#18923) (#18938) 3 years ago
notification Fix problem when self-assign notification (#18797) (#18976) 3 years ago
options Remove golang vendored directory (#18277) 3 years ago
password Fixed assert statements. (#16089) 4 years ago
pprof refactor: move from io/ioutil to io and os package (#17109) 3 years ago
private Fix the bug: deploy key with write access can not push (#19010) (#19182) 3 years ago
process Fix various typos (#18219) 3 years ago
proxy Return nil proxy function if proxy not enabled (#16742) 4 years ago
public Fix mime-type detection for HTTP server (#18371) 3 years ago
queue In disk_channel queues synchronously push to disk on shutdown (#18415) (#18788) 3 years ago
recaptcha refactor: move from io/ioutil to io and os package (#17109) 3 years ago
references Add API to get issue/pull comments and events (timeline) (#17403) 3 years ago
repository Use full output of git show-ref --tags to get tags for PushUpdateAddTag (#19235) (#19236) 3 years ago
secret Simplify parameter types (#18006) 3 years ago
session Refactor auth package (#17962) 3 years ago
setting Only request write when necessary (#18657) (#19422) 3 years ago
ssh Update golang.org/x/crypto (#19097) (#19098) 3 years ago
storage Clean paths when looking in Storage (#19124) (#19179) 3 years ago
structs When updating mirror repo intervals by API reschedule next update too (#19429) (#19433) 3 years ago
svg refactor: move from io/ioutil to io and os package (#17109) 3 years ago
sync Fix missing unlock in uniquequeue (#9790) 5 years ago
templates Prevent start panic due to missing DotEscape function 3 years ago
test Unify and simplify TrN for i18n (#18141) 3 years ago
timeutil Don't store assets modified time into generated files (#18193) 3 years ago
translation Sort locales according to their names (#18211) 3 years ago
typesniffer Read expected buffer size (#17409) 3 years ago
updatechecker Fix various typos (#18219) 3 years ago
upload Simplify parameter types (#18006) 3 years ago
uri Prevent NPE if gitea uploader fails to open url (#18080) 3 years ago
user Add gitea-vet (#10948) 5 years ago
util Revert the minimal golang version requirement from 1.17 to 1.16 and add a warning in Makefile (#19319) 3 years ago
validation Upgrade chi to v5 (#17298) 3 years ago
web Simplify parameter types (#18006) 3 years ago