|
|
@ -208,6 +208,7 @@ func (v *Volume) Destroy() (err error) { |
|
|
|
} |
|
|
|
|
|
|
|
func (v *Volume) write(n *Needle) (size uint32, err error) { |
|
|
|
glog.V(4).Infof("writing needle %s", NewFileIdFromNeedle(v.Id, n).String()) |
|
|
|
if v.readOnly { |
|
|
|
err = fmt.Errorf("%s is read-only", v.dataFile) |
|
|
|
return |
|
|
@ -249,6 +250,7 @@ func (v *Volume) write(n *Needle) (size uint32, err error) { |
|
|
|
} |
|
|
|
|
|
|
|
func (v *Volume) delete(n *Needle) (uint32, error) { |
|
|
|
glog.V(4).Infof("delete needle %s", NewFileIdFromNeedle(v.Id, n).String()) |
|
|
|
if v.readOnly { |
|
|
|
return 0, fmt.Errorf("%s is read-only", v.dataFile) |
|
|
|
} |
|
|
|