Browse Source

weed/storage: Fix volume info file permissions (#5246)

pull/5251/head
Benoît Knecht 11 months ago
committed by GitHub
parent
commit
f6e39139d8
No known key found for this signature in database GPG Key ID: B5690EEEBB952194
  1. 5
      weed/storage/volume_info/volume_info.go

5
weed/storage/volume_info/volume_info.go

@ -76,9 +76,8 @@ func SaveVolumeInfo(fileName string, volumeInfo *volume_server_pb.VolumeInfo) er
return fmt.Errorf("failed to marshal %s: %v", fileName, marshalErr)
}
writeErr := util.WriteFile(fileName, text, 0755)
if writeErr != nil {
return fmt.Errorf("failed to write %s: %v", fileName, writeErr)
if err := util.WriteFile(fileName, text, 0644); err != nil {
return fmt.Errorf("failed to write %s: %v", fileName, err)
}
return nil

Loading…
Cancel
Save