Skip to content

SeaweedFS is a distributed storage system for object storage (S3), file systems, Iceberg table buckets, and Lance vector buckets, designed to handle billions of files with O(1) disk access and effortless horizontal scaling.

fix compilation on windows

chrislu896096c41ba4
diff --git a/weed/sftpd/sftp_filer.go b/weed/sftpd/sftp_filer.go
index 4cc709390a..16fec90baf 100644
--- a/weed/sftpd/sftp_filer.go
+++ b/weed/sftpd/sftp_filer.go
@@ -12,7 +12,6 @@ import (
"os"
"path"
"strings"
- "syscall"
"time"
"github.com/pkg/sftp"
@@ -377,8 +376,14 @@ type EnhancedFileInfo struct {
gid uint32
}
+// FileStat represents file statistics in a platform-independent way
+type FileStat struct {
+ Uid uint32
+ Gid uint32
+}
+
func (fi *EnhancedFileInfo) Sys() interface{} {
- return &syscall.Stat_t{Uid: fi.uid, Gid: fi.gid}
+ return &FileStat{Uid: fi.uid, Gid: fi.gid}
}
func (fi *EnhancedFileInfo) Owner() (uid, gid int) {