continued work on encryption

This commit is contained in:
ston1th 2022-04-07 00:54:13 +02:00
commit 880e2f06b3
14 changed files with 362 additions and 39 deletions

View file

@ -2,6 +2,7 @@ package crypto
import (
"cachefs/pkg/provider"
osp "cachefs/pkg/provider/os"
"encoding/base64"
"errors"
"io/fs"
@ -102,7 +103,11 @@ func (fs *FS) Root() string {
return fs.fs.Root()
}
func (fs *FS) Fstat(_ uintptr) (int64, error) {
func (fs *FS) Fstat(fd uintptr) (int64, error) {
osp, ok := fs.fs.(*osp.FS)
if ok {
return osp.Fstat(fd)
}
return 0, provider.ErrFstat
}