mirror of
https://github.com/superseriousbusiness/gotosocial.git
synced 2025-10-29 21:02:26 -05:00
[chore] Bump database dependencies (#1164)
github.com/uptrace/bun v1.1.8 -> v1.1.9 github.com/uptrace/bun/pgdialect v1.1.8 -> v1.1.9 github.com/uptrace/bun/sqlitedialect v1.1.8 -> v1.1.9 modernc.org/sqlite v1.18.2 -> v1.19.5
This commit is contained in:
parent
fe39d50e09
commit
daf44ac2b7
529 changed files with 971879 additions and 1370194 deletions
35
vendor/modernc.org/libc/libc_windows_386.go
generated
vendored
35
vendor/modernc.org/libc/libc_windows_386.go
generated
vendored
|
|
@ -11,6 +11,7 @@ import (
|
|||
"unsafe"
|
||||
|
||||
"modernc.org/libc/errno"
|
||||
"modernc.org/libc/sys/stat"
|
||||
"modernc.org/libc/sys/types"
|
||||
)
|
||||
|
||||
|
|
@ -546,3 +547,37 @@ func XDefWindowProcW(t *TLS, _ ...interface{}) int32 {
|
|||
func XSendMessageTimeoutW(t *TLS, _ ...interface{}) int32 {
|
||||
panic(todo(""))
|
||||
}
|
||||
|
||||
// int _fstat(
|
||||
//
|
||||
// int fd,
|
||||
// struct __stat *buffer
|
||||
//
|
||||
// );
|
||||
func X_fstat(t *TLS, fd int32, buffer uintptr) int32 {
|
||||
f, ok := fdToFile(fd)
|
||||
if !ok {
|
||||
t.setErrno(EBADF)
|
||||
return -1
|
||||
}
|
||||
|
||||
var d syscall.ByHandleFileInformation
|
||||
err := syscall.GetFileInformationByHandle(f.Handle, &d)
|
||||
if err != nil {
|
||||
t.setErrno(EBADF)
|
||||
return -1
|
||||
}
|
||||
|
||||
var bStat32 = (*stat.X_stat32)(unsafe.Pointer(buffer))
|
||||
var accessTime = int64(d.LastAccessTime.HighDateTime)<<32 + int64(d.LastAccessTime.LowDateTime)
|
||||
bStat32.Fst_atime = int32(WindowsTickToUnixSeconds(accessTime))
|
||||
var modTime = int64(d.LastWriteTime.HighDateTime)<<32 + int64(d.LastWriteTime.LowDateTime)
|
||||
bStat32.Fst_mtime = int32(WindowsTickToUnixSeconds(modTime))
|
||||
var crTime = int64(d.CreationTime.HighDateTime)<<32 + int64(d.CreationTime.LowDateTime)
|
||||
bStat32.Fst_ctime = int32(WindowsTickToUnixSeconds(crTime))
|
||||
var fSz = int64(d.FileSizeHigh)<<32 + int64(d.FileSizeLow)
|
||||
bStat32.Fst_size = int32(fSz)
|
||||
bStat32.Fst_mode = WindowsAttrbiutesToStat(d.FileAttributes)
|
||||
|
||||
return 0
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue