Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
|
#include <QtCore/private/qglobal_p.h>
#include <QtCore/qbasicatomic.h>
#include "qcore_unix_p.h"
#include <stdlib.h>
Go to the source code of this file.
Macros | |
#define | PATH_MAX 1024*1024 |
Functions | |
QT_BEGIN_NAMESPACE void | qt_ignore_sigpipe () noexcept |
QByteArray | qt_readlink (const char *path) |
static int | timespecToMillisecs (const struct timespec *ts) |
int | qt_poll (struct pollfd *fds, nfds_t nfds, const struct timespec *timeout_ts) |
static int | qt_ppoll (struct pollfd *fds, nfds_t nfds, const struct timespec *timeout_ts) |
int | qt_safe_poll (struct pollfd *fds, nfds_t nfds, QDeadlineTimer deadline) |
#define PATH_MAX 1024*1024 |
|
noexcept |
Definition at line 23 of file qcore_unix.cpp.
References Q_BASIC_ATOMIC_INITIALIZER.
Referenced by qt_safe_sendmsg(), and qt_safe_write_nosignal().
int qt_poll | ( | struct pollfd * | fds, |
nfds_t | nfds, | ||
const struct timespec * | timeout_ts ) |
Definition at line 136 of file qpoll.cpp.
References forever, i, QT_POLL_EVENTS_MASK, qt_poll_is_bad_fd(), qt_poll_mark_bad_fds(), qt_poll_prepare(), qt_poll_sweep(), ret, select(), and timespecToTimeval().
Referenced by qt_ppoll().
|
inlinestatic |
Definition at line 100 of file qcore_unix.cpp.
References qt_poll(), and timespecToMillisecs().
Referenced by qt_safe_poll().
QByteArray qt_readlink | ( | const char * | path | ) |
Definition at line 38 of file qcore_unix.cpp.
References PATH_MAX, QByteArray(), and Qt::Uninitialized.
Referenced by QFileSystemEngine::getLinkTarget(), QFileSystemEngine::getRawLinkPath(), QLockFilePrivate::processNameByPid(), and qAppFileName().
int qt_safe_poll | ( | struct pollfd * | fds, |
nfds_t | nfds, | ||
QDeadlineTimer | deadline ) |
Behaves as close to POSIX poll(2) as practical but may be implemented using select(2) where necessary. In that case, returns -1 and sets errno to EINVAL if passed any descriptor greater than or equal to FD_SETSIZE.
Definition at line 121 of file qcore_unix.cpp.
References deadline, durationToTimespec(), QDeadlineTimer::isForever(), QT_EINTR_LOOP, qt_ppoll(), QDeadlineTimer::remainingTimeAsDuration(), and ret.
Referenced by QNativeSocketEnginePrivate::nativeSelect(), and QEventDispatcherUNIX::processEvents().
|
inlinestatic |
Definition at line 88 of file qcore_unix.cpp.
Referenced by qt_ppoll().