unix: define Time_t for FreeBSD

Fixes golang/go#48148

Change-Id: I8c0a62b204689fc6ac9e29b1ba0b084e3d807323
Reviewed-on: https://go-review.googlesource.com/c/sys/+/348012
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
This commit is contained in:
jharshman
2021-09-07 12:41:54 -06:00
committed by Ian Lance Taylor
parent a851e7ddee
commit aa78b53d33
5 changed files with 10 additions and 0 deletions

View File

@@ -141,6 +141,8 @@ type Timespec C.struct_timespec
type Timeval C.struct_timeval
type Time_t C.time_t
// Processes
type Rusage C.struct_rusage

View File

@@ -31,6 +31,8 @@ type Timeval struct {
Usec int32
}
type Time_t int32
type Rusage struct {
Utime Timeval
Stime Timeval

View File

@@ -31,6 +31,8 @@ type Timeval struct {
Usec int64
}
type Time_t int64
type Rusage struct {
Utime Timeval
Stime Timeval

View File

@@ -33,6 +33,8 @@ type Timeval struct {
_ [4]byte
}
type Time_t int32
type Rusage struct {
Utime Timeval
Stime Timeval

View File

@@ -31,6 +31,8 @@ type Timeval struct {
Usec int64
}
type Time_t int64
type Rusage struct {
Utime Timeval
Stime Timeval