Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
G
golang
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
go
golang
Commits
08852ffe
Commit
08852ffe
authored
Apr 09, 2010
by
Russ Cox
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
freebsd: fix build, maybe
R=r CC=golang-dev
https://golang.org/cl/909041
parent
3c3e68ba
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
17 deletions
+17
-17
stat_freebsd.go
src/pkg/os/stat_freebsd.go
+17
-17
No files found.
src/pkg/os/stat_freebsd.go
View file @
08852ffe
...
@@ -10,29 +10,29 @@ func isSymlink(stat *syscall.Stat_t) bool {
...
@@ -10,29 +10,29 @@ func isSymlink(stat *syscall.Stat_t) bool {
return
stat
.
Mode
&
syscall
.
S_IFMT
==
syscall
.
S_IFLNK
return
stat
.
Mode
&
syscall
.
S_IFMT
==
syscall
.
S_IFLNK
}
}
func
dirFromStat
(
name
string
,
dir
*
Dir
,
lstat
,
stat
*
syscall
.
Stat_t
)
*
Dir
{
func
fileInfoFromStat
(
name
string
,
fi
*
FileInfo
,
lstat
,
stat
*
syscall
.
Stat_t
)
*
FileInfo
{
dir
.
Dev
=
uint64
(
stat
.
Dev
)
fi
.
Dev
=
uint64
(
stat
.
Dev
)
dir
.
Ino
=
uint64
(
stat
.
Ino
)
fi
.
Ino
=
uint64
(
stat
.
Ino
)
dir
.
Nlink
=
uint64
(
stat
.
Nlink
)
fi
.
Nlink
=
uint64
(
stat
.
Nlink
)
dir
.
Mode
=
uint32
(
stat
.
Mode
)
fi
.
Mode
=
uint32
(
stat
.
Mode
)
dir
.
Uid
=
stat
.
Uid
fi
.
Uid
=
stat
.
Uid
dir
.
Gid
=
stat
.
Gid
fi
.
Gid
=
stat
.
Gid
dir
.
Rdev
=
uint64
(
stat
.
Rdev
)
fi
.
Rdev
=
uint64
(
stat
.
Rdev
)
dir
.
Size
=
uint64
(
stat
.
Size
)
fi
.
Size
=
uint64
(
stat
.
Size
)
dir
.
Blksize
=
uint64
(
stat
.
Blksize
)
fi
.
Blksize
=
uint64
(
stat
.
Blksize
)
dir
.
Blocks
=
uint64
(
stat
.
Blocks
)
fi
.
Blocks
=
uint64
(
stat
.
Blocks
)
dir
.
Atime_ns
=
uint64
(
syscall
.
TimespecToNsec
(
stat
.
Atimespec
))
fi
.
Atime_ns
=
uint64
(
syscall
.
TimespecToNsec
(
stat
.
Atimespec
))
dir
.
Mtime_ns
=
uint64
(
syscall
.
TimespecToNsec
(
stat
.
Mtimespec
))
fi
.
Mtime_ns
=
uint64
(
syscall
.
TimespecToNsec
(
stat
.
Mtimespec
))
dir
.
Ctime_ns
=
uint64
(
syscall
.
TimespecToNsec
(
stat
.
Ctimespec
))
fi
.
Ctime_ns
=
uint64
(
syscall
.
TimespecToNsec
(
stat
.
Ctimespec
))
for
i
:=
len
(
name
)
-
1
;
i
>=
0
;
i
--
{
for
i
:=
len
(
name
)
-
1
;
i
>=
0
;
i
--
{
if
name
[
i
]
==
'/'
{
if
name
[
i
]
==
'/'
{
name
=
name
[
i
+
1
:
]
name
=
name
[
i
+
1
:
]
break
break
}
}
}
}
dir
.
Name
=
name
fi
.
Name
=
name
if
isSymlink
(
lstat
)
&&
!
isSymlink
(
stat
)
{
if
isSymlink
(
lstat
)
&&
!
isSymlink
(
stat
)
{
dir
.
FollowedSymlink
=
true
fi
.
FollowedSymlink
=
true
}
}
return
dir
return
fi
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment