mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2024-11-27 20:59:42 +08:00
avoid integer overflow
fix https://github.com/chrislusf/seaweedfs/issues/2254
This commit is contained in:
parent
5516fa8e80
commit
bfac55e6c0
@ -35,7 +35,9 @@ func NewFilerRemoteStorage() (rs *FilerRemoteStorage) {
|
||||
func (rs *FilerRemoteStorage) LoadRemoteStorageConfigurationsAndMapping(filer *Filer) (err error) {
|
||||
// execute this on filer
|
||||
|
||||
entries, _, err := filer.ListDirectoryEntries(context.Background(), DirectoryEtcRemote, "", false, math.MaxInt64, "", "", "")
|
||||
limit := int64(math.MaxInt32)
|
||||
|
||||
entries, _, err := filer.ListDirectoryEntries(context.Background(), DirectoryEtcRemote, "", false, limit, "", "", "")
|
||||
if err != nil {
|
||||
if err == filer_pb.ErrNotFound {
|
||||
return nil
|
||||
|
Loading…
Reference in New Issue
Block a user