qt: rebuild (identify more linuxonly quirks in qsocketnotifier)

This commit is contained in:
mappu 2025-04-11 22:21:39 +12:00
parent aff87f98a2
commit beb33ce780
4 changed files with 16 additions and 0 deletions

View File

@ -451,7 +451,11 @@ void QSocketNotifier_delete(QSocketNotifier* self) {
}
QSocketDescriptor* QSocketDescriptor_new() {
#ifndef Q_OS_LINUX
return nullptr;
#else
return new QSocketDescriptor();
#endif
}
QSocketDescriptor* QSocketDescriptor_new2(QSocketDescriptor* param1) {

View File

@ -453,6 +453,10 @@ func UnsafeNewQSocketDescriptor(h unsafe.Pointer) *QSocketDescriptor {
// NewQSocketDescriptor constructs a new QSocketDescriptor object.
func NewQSocketDescriptor() *QSocketDescriptor {
if runtime.GOOS != "linux" {
panic("Unsupported OS")
}
return newQSocketDescriptor(C.QSocketDescriptor_new())
}

View File

@ -436,7 +436,11 @@ void QSocketNotifier_delete(QSocketNotifier* self) {
}
QSocketDescriptor* QSocketDescriptor_new() {
#ifndef Q_OS_LINUX
return nullptr;
#else
return new QSocketDescriptor();
#endif
}
QSocketDescriptor* QSocketDescriptor_new2(QSocketDescriptor* param1) {

View File

@ -442,6 +442,10 @@ func UnsafeNewQSocketDescriptor(h unsafe.Pointer) *QSocketDescriptor {
// NewQSocketDescriptor constructs a new QSocketDescriptor object.
func NewQSocketDescriptor() *QSocketDescriptor {
if runtime.GOOS != "linux" {
panic("Unsupported OS")
}
return newQSocketDescriptor(C.QSocketDescriptor_new())
}