bump modernc.org/sqlite to v1.35.0-concurrency-workaround (#3797)

This commit is contained in:
kim 2025-02-14 16:54:10 +00:00 committed by GitHub
commit ebbdeee0bb
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
114 changed files with 891873 additions and 192475 deletions

View file

@ -15,7 +15,6 @@ import (
"path/filepath"
"runtime"
"strings"
"syscall"
gotime "time"
"unicode"
"unsafe"
@ -51,8 +50,9 @@ const (
// )
type (
long = types.User_long_t
ulong = types.User_ulong_t
syscallErrno = unix.Errno
long = types.User_long_t
ulong = types.User_ulong_t
)
type pthreadAttr struct {
@ -1098,7 +1098,7 @@ func Xfileno(t *TLS, stream uintptr) int32 {
return -1
}
func newFtsent(t *TLS, info int, path string, stat *unix.Stat_t, err syscall.Errno) (r *fts.FTSENT) {
func newFtsent(t *TLS, info int, path string, stat *unix.Stat_t, err syscallErrno) (r *fts.FTSENT) {
var statp uintptr
if stat != nil {
statp = Xmalloc(t, types.Size_t(unsafe.Sizeof(unix.Stat_t{})))
@ -1122,7 +1122,7 @@ func newFtsent(t *TLS, info int, path string, stat *unix.Stat_t, err syscall.Err
}
}
func newCFtsent(t *TLS, info int, path string, stat *unix.Stat_t, err syscall.Errno) uintptr {
func newCFtsent(t *TLS, info int, path string, stat *unix.Stat_t, err syscallErrno) uintptr {
p := Xcalloc(t, 1, types.Size_t(unsafe.Sizeof(fts.FTSENT{})))
if p == 0 {
panic("OOM")
@ -1513,7 +1513,7 @@ func Xabort(t *TLS) {
(*signal.Sigaction)(unsafe.Pointer(p)).F__sigaction_u.F__sa_handler = signal.SIG_DFL
Xsigaction(t, signal.SIGABRT, p, 0)
Xfree(t, p)
unix.Kill(unix.Getpid(), syscall.Signal(signal.SIGABRT))
unix.Kill(unix.Getpid(), unix.Signal(signal.SIGABRT))
panic(todo("unrechable"))
}
@ -1765,7 +1765,7 @@ func Xgetservbyname(t *TLS, name, proto uintptr) uintptr {
// //TODO- return Xreaddir(t, dir)
// //TODO- }
//
// func __syscall(r, _ uintptr, errno syscall.Errno) long {
// func __syscall(r, _ uintptr, errno syscallErrno) long {
// if errno != 0 {
// return long(-errno)
// }
@ -2055,7 +2055,7 @@ func Xpipe(t *TLS, pipefd uintptr) int32 {
trc("t=%v pipefd=%v, (%v:)", t, pipefd, origin(2))
}
var a [2]int
if err := syscall.Pipe(a[:]); err != nil {
if err := unix.Pipe(a[:]); err != nil {
if dmesgs {
dmesg("%v: %v FAIL", origin(1), err)
}
@ -2234,39 +2234,39 @@ func Xpause(t *TLS) int32 {
}
c := make(chan os.Signal)
gosignal.Notify(c,
syscall.SIGABRT,
syscall.SIGALRM,
syscall.SIGBUS,
syscall.SIGCHLD,
syscall.SIGCONT,
syscall.SIGFPE,
syscall.SIGHUP,
syscall.SIGILL,
// syscall.SIGINT,
syscall.SIGIO,
syscall.SIGIOT,
syscall.SIGKILL,
syscall.SIGPIPE,
syscall.SIGPROF,
syscall.SIGQUIT,
syscall.SIGSEGV,
syscall.SIGSTOP,
syscall.SIGSYS,
syscall.SIGTERM,
syscall.SIGTRAP,
syscall.SIGTSTP,
syscall.SIGTTIN,
syscall.SIGTTOU,
syscall.SIGURG,
syscall.SIGUSR1,
syscall.SIGUSR2,
syscall.SIGVTALRM,
syscall.SIGWINCH,
syscall.SIGXCPU,
syscall.SIGXFSZ,
unix.SIGABRT,
unix.SIGALRM,
unix.SIGBUS,
unix.SIGCHLD,
unix.SIGCONT,
unix.SIGFPE,
unix.SIGHUP,
unix.SIGILL,
// unix.SIGINT,
unix.SIGIO,
unix.SIGIOT,
unix.SIGKILL,
unix.SIGPIPE,
unix.SIGPROF,
unix.SIGQUIT,
unix.SIGSEGV,
unix.SIGSTOP,
unix.SIGSYS,
unix.SIGTERM,
unix.SIGTRAP,
unix.SIGTSTP,
unix.SIGTTIN,
unix.SIGTTOU,
unix.SIGURG,
unix.SIGUSR1,
unix.SIGUSR2,
unix.SIGVTALRM,
unix.SIGWINCH,
unix.SIGXCPU,
unix.SIGXFSZ,
)
switch <-c {
case syscall.SIGINT:
case unix.SIGINT:
panic(todo(""))
default:
t.setErrno(errno.EINTR)
@ -2510,3 +2510,11 @@ func X__fpclassifyd(tls *TLS, x float64) (r int32) {
}
var Xin6addr_any = in6_addr{}
func X__builtin_lround(tls *TLS, x float64) (r long) {
return Xlround(tls, x)
}
func Xlround(tls *TLS, x float64) (r long) {
return long(Xround(tls, x))
}