Update FileAttributes size to work on 32 bit platforms

This commit is contained in:
Jiri Appl
2018-08-02 10:42:57 -07:00
parent a6d595ae73
commit 350b9857de
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -303,7 +303,7 @@ func FileInfoFromHeader(hdr *tar.Header) (name string, size int64, fileInfo *win
if err != nil {
return "", 0, nil, err
}
fileInfo.FileAttributes = uintptr(attr)
fileInfo.FileAttributes = attr
} else {
if hdr.Typeflag == tar.TypeDir {
fileInfo.FileAttributes |= syscall.FILE_ATTRIBUTE_DIRECTORY
+1 -1
View File
@@ -20,7 +20,7 @@ const (
// FileBasicInfo contains file access time and file attributes information.
type FileBasicInfo struct {
CreationTime, LastAccessTime, LastWriteTime, ChangeTime syscall.Filetime
FileAttributes uintptr // includes padding
FileAttributes uint64 // includes padding
}
// GetFileBasicInfo retrieves times and attributes for a file.