update 2026-08-31 02:59:36

This commit is contained in:
action committed 2026-08-31 02:59:36 +08:00
1 parent 4fe683a80b
commit 72ace44e3b
1975 files changed
+1523205 -20

No files matched your search

+1 -1
View File
@@ -7,7 +7,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=BaiduPCS-Go
PKG_VERSION:=3.9.0
PKG_RELEASE:=1
PKG_RELEASE:=2
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://codeload.github.com/qjfoidnh/BaiduPCS-Go/tar.gz/v$(PKG_VERSION)?
@@ -0,0 +1,25 @@
From: coolsnowwolf <coolsnowwolf@gmail.com>
Subject: [PATCH] cachepool: stop using runtime.rawbyteslice
Recent Go releases reject external linkname references to rawbyteslice.
Use the language-provided slice allocator for the zeroed allocation path.
Signed-off-by: coolsnowwolf <coolsnowwolf@gmail.com>
---
--- a/pcsutil/cachepool/malloc.go
+++ b/pcsutil/cachepool/malloc.go
@@ -8,12 +8,9 @@
//go:linkname mallocgc runtime.mallocgc
func mallocgc(size uintptr, typ uintptr, needzero bool) unsafe.Pointer
-//go:linkname rawbyteslice runtime.rawbyteslice
-func rawbyteslice(size int) (b []byte)
-
-// RawByteSlice point to runtime.rawbyteslice
+// RawByteSlice allocates a zeroed byte slice.
func RawByteSlice(size int) (b []byte) {
- return rawbyteslice(size)
+ return make([]byte, size)
}
// RawMalloc allocates a new slice. The slice is not zeroed.