mirror of
https://github.com/restic/restic.git
synced 2026-08-21 13:03:25 +00:00
fix comment and variable name typos
This commit is contained in:
@@ -160,7 +160,7 @@ func setFileEA(handle windows.Handle, iosb *ioStatusBlock, buf *uint8, bufLen ui
|
||||
return
|
||||
}
|
||||
|
||||
// pathSupportsExtendedAttributes returns true if the path supports extended attributes.
|
||||
// pathSupportsExtendedAttributes reports whether the path's volume supports extended attributes.
|
||||
func pathSupportsExtendedAttributes(path string) (supported bool, err error) {
|
||||
var fileSystemFlags uint32
|
||||
utf16Path, err := windows.UTF16PtrFromString(path)
|
||||
|
||||
@@ -49,7 +49,7 @@ type ErrorHandler func(item string, err error)
|
||||
// MessageHandler is used to report errors/messages via callbacks.
|
||||
type MessageHandler func(msg string, args ...interface{})
|
||||
|
||||
// VolumeFilter is used to filter volumes by it's mount point or GUID path.
|
||||
// VolumeFilter is used to filter volumes by their mount point or GUID path.
|
||||
type VolumeFilter func(volume string) bool
|
||||
|
||||
// LocalVss is a wrapper around the local file system which uses windows volume
|
||||
|
||||
@@ -292,7 +292,7 @@ func fixEncryptionAttribute(path string, attrs *uint32, pathPointer *uint16) (er
|
||||
return fmt.Errorf("failed to get file attributes for existing file: %s : %v", path, err)
|
||||
}
|
||||
if existingAttrs&windows.FILE_ATTRIBUTE_ENCRYPTED != 0 {
|
||||
// File should not be encrypted, but its already encrypted. Decrypt it.
|
||||
// File should not be encrypted, but it's already encrypted. Decrypt it.
|
||||
err = decryptFile(pathPointer)
|
||||
if err != nil {
|
||||
if IsAccessDenied(err) || errors.Is(err, windows.ERROR_FILE_READ_ONLY) {
|
||||
|
||||
+1
-1
@@ -27,7 +27,7 @@ type VssSnapshot struct {
|
||||
mountPointInfo map[string]MountPoint
|
||||
}
|
||||
|
||||
// HasSufficientPrivilegesForVSS returns true if the user is allowed to use VSS.
|
||||
// HasSufficientPrivilegesForVSS returns nil if the user is allowed to use VSS.
|
||||
func HasSufficientPrivilegesForVSS() error {
|
||||
return errors.New("VSS snapshots are only supported on windows")
|
||||
}
|
||||
|
||||
@@ -1244,7 +1244,7 @@ func queryInterface(oleIUnknown *ole.IUnknown, guid *ole.GUID) (*interface{}, er
|
||||
return ivss, nil
|
||||
}
|
||||
|
||||
// isRunningOn64BitWindows returns true if running on 64-bit windows.
|
||||
// isRunningOn64BitWindows reports whether the process is running on 64-bit Windows.
|
||||
func isRunningOn64BitWindows() (bool, error) {
|
||||
if runtime.GOARCH == "amd64" {
|
||||
return true, nil
|
||||
|
||||
Reference in New Issue
Block a user