feat(阅读编辑): 优化大文件阅读编辑、页码显示,修复异常日期
build.yaml / build (push) Successful in 41s

This commit is contained in:
xiaoqidun committed 2026-09-24 00:27:02 +08:00
1 parent e3908c1149
commit 46e6d5b622
9 files changed
+611 -152

No files matched your search

+7 -3
View File
@@ -92,9 +92,13 @@ func (r *Reader) initRoot() error {
// indexPackage 建立包路径索引,拒绝会使显示与验签产生歧义的同名条目
// 返回: error 错误信息
func (r *Reader) indexPackage() error {
r.fileIndex = make(map[string]*zip.File)
r.fileIndexFold = make(map[string]*zip.File)
r.fileNamesFold = make(map[string]string)
count := 0
if r.Zip != nil {
count = len(r.Zip.File)
}
r.fileIndex = make(map[string]*zip.File, count)
r.fileIndexFold = make(map[string]*zip.File, count)
r.fileNamesFold = make(map[string]string, count+len(r.files))
if r.Zip != nil {
for _, f := range r.Zip.File {
if f.FileInfo().IsDir() {