forgejo/modules
oliverpool 225a0f7026 git/TreeEntry: LinkTarget simplification (#8323)
See #8222 for context.

This PR removes a call to `Blob.GetBlobContent` and `Blob.DataAsync` and unifies symlink resolution:
- length was unlimited in one case
- length was truncated to 1024 chars in the other case

Now it is hard-limited to 4096 chars (ie error if larger), which is a length which seems appropriate according to https://stackoverflow.com/a/22575737.

### Tests

- Tests are already present in `tests/integration/repo_test.go:972`: `TestRepoFollowSymlink` (it caught a cap/len stupid mistake).
- [x] I did not document these changes and I do not expect someone else to do it.
- [x] I do not want this change to show in the release notes.

Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/8323
Reviewed-by: Earl Warren <earl-warren@noreply.codeberg.org>
Co-authored-by: oliverpool <git@olivier.pfad.fr>
Co-committed-by: oliverpool <git@olivier.pfad.fr>
2025-06-27 23:10:09 +02:00
..
actions [gitea] week 2025-22 cherry pick (gitea/main -> forgejo) (#8198) 2025-06-17 18:28:07 +02:00
activitypub fix various typos (#7690) 2025-04-28 06:46:29 +00:00
analyze
assetfs feat: improve generation of bundled assets (#8143) 2025-06-11 09:36:18 +02:00
auth chore(cleanup): replaces unnecessary calls to formatting functions by non-formatting equivalents (#7994) 2025-05-29 17:34:29 +02:00
avatar chore(cleanup): replaces unnecessary calls to formatting functions by non-formatting equivalents (#7994) 2025-05-29 17:34:29 +02:00
base
cache chore(cleanup): replaces unnecessary calls to formatting functions by non-formatting equivalents (#7994) 2025-05-29 17:34:29 +02:00
card
charset feat: update ambigious characters (#7988) 2025-05-29 10:00:12 +02:00
container
csv
emoji chore(cleanup): replaces unnecessary calls to formatting functions by non-formatting equivalents (#7994) 2025-05-29 17:34:29 +02:00
eventsource
forgefed refactor & enhance AP elements used (#7728) 2025-06-02 22:29:10 +02:00
generate
git git/TreeEntry: LinkTarget simplification (#8323) 2025-06-27 23:10:09 +02:00
gitrepo
graceful
hcaptcha
highlight
hostmatcher
html
httpcache
httplib fix: omit Content-Length on 307 redirects when serving direct manifest for containers (#8037) 2025-06-09 08:43:41 +02:00
indexer feat: show more relevant results for 'dependencies' dropdown (#8003) 2025-06-26 20:06:21 +02:00
issue/template chore(cleanup): replaces unnecessary calls to formatting functions by non-formatting equivalents (#7994) 2025-05-29 17:34:29 +02:00
json
keying
label
lfs
log
markup fix(ui): add missing lazy load attribute to images (#8246) 2025-06-25 18:31:03 +02:00
mcaptcha
metrics
migration
nosql
optional
options
packages feat: support artifact uploads for OCI container packages (#8070) 2025-06-09 10:14:53 +02:00
paginator
pprof
private
process
proxy
proxyprotocol
public add model viewer for .glb (GLTF) model in file view (#8111) 2025-06-21 14:42:35 +02:00
queue chore: QoL improvements to tests (#7917) 2025-05-21 15:45:56 +02:00
recaptcha
references fix: pull request cross references (#7979) 2025-05-28 14:50:05 +02:00
regexplru
repository feat: configurable default units for mirrors (#7902) 2025-06-03 08:12:29 +02:00
secret
session
setting feat: enable mlkem768x25519-sha256 by default for builtin ssh (#8115) 2025-06-09 14:34:15 +02:00
sitemap
ssh
storage chore(ci): skip tests if TEST_{MINIO_ENDPOINT,ELASTICSEARCH_URL} is not set (#8166) 2025-06-12 21:13:52 +02:00
structs Revert "fix(api): document is_system_webhook field (#7784)" (#8286) 2025-06-26 00:36:18 +02:00
svg
sync
system
templates fix(ui): add missing lazy load attribute to images (#8246) 2025-06-25 18:31:03 +02:00
test chore: QoL improvements to tests (#7917) 2025-05-21 15:45:56 +02:00
testlogger
timeutil
translation Replace the 'relative-time' element scripting with custom, translatable rewrite (#6154) 2025-05-03 14:11:01 +00:00
turnstile
typesniffer add model viewer for .glb (GLTF) model in file view (#8111) 2025-06-21 14:42:35 +02:00
updatechecker
uri
user
util blob: GetBlobContent: reduce allocations (#8223) 2025-06-19 18:36:12 +02:00
validation fix: allow instance API URLs in release assets (#7644) 2025-06-09 10:01:59 +02:00
web feat: make Forgejo Actions server logs less noisy (#7986) 2025-05-29 10:06:30 +02:00
webhook Actions Failure, Succes, Recover Webhooks (#7508) 2025-06-03 14:29:19 +02:00
zstd