aboutsummaryrefslogtreecommitdiff
path: root/weed/storage/volume_loading.go
diff options
context:
space:
mode:
Diffstat (limited to 'weed/storage/volume_loading.go')
-rw-r--r--weed/storage/volume_loading.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/weed/storage/volume_loading.go b/weed/storage/volume_loading.go
index d90439822..bdf9984e5 100644
--- a/weed/storage/volume_loading.go
+++ b/weed/storage/volume_loading.go
@@ -16,11 +16,11 @@ func loadVolumeWithoutIndex(dirname string, collection string, id needle.VolumeI
v = &Volume{dir: dirname, Collection: collection, Id: id}
v.SuperBlock = SuperBlock{}
v.needleMapKind = needleMapKind
- e = v.load(false, false, needleMapKind, 0, false)
+ e = v.load(false, false, needleMapKind, 0)
return
}
-func (v *Volume) load(alsoLoadIndex bool, createDatIfMissing bool, needleMapKind NeedleMapType, preallocate int64, in_memory bool) error {
+func (v *Volume) load(alsoLoadIndex bool, createDatIfMissing bool, needleMapKind NeedleMapType, preallocate int64) error {
var e error
fileName := v.FileName()
alreadyHasSuperBlock := false
@@ -42,7 +42,7 @@ func (v *Volume) load(alsoLoadIndex bool, createDatIfMissing bool, needleMapKind
}
} else {
if createDatIfMissing {
- v.dataFile, e = createVolumeFile(fileName+".dat", preallocate, in_memory)
+ v.dataFile, e = createVolumeFile(fileName+".dat", preallocate, v.MemoryMapped)
} else {
return fmt.Errorf("Volume Data file %s.dat does not exist.", fileName)
}