QNX: Make use of _readdir64_r
Latest QNX versions support _readdir64_r. It will be used by QFileSystemIterator now, when available to support large file systems. Change-Id: I40135f405ad72e1ba85c6a4cd282144dd8171bc6 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Thomas McGuire <thomas.mcguire@kdab.com> Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
This commit is contained in:
parent
92b2275c3d
commit
5d8c05baf4
@ -83,8 +83,15 @@
|
||||
#include <arpa/inet.h>
|
||||
|
||||
#define QT_USE_XOPEN_LFS_EXTENSIONS
|
||||
#if !defined(__EXT_QNX__READDIR64_R)
|
||||
#define QT_NO_READDIR64
|
||||
#endif
|
||||
#include "../common/posix/qplatformdefs.h"
|
||||
#if defined(__EXT_QNX__READDIR64_R)
|
||||
#define QT_EXT_QNX_READDIR_R ::_readdir64_r
|
||||
#elif defined(__EXT_QNX__READDIR_R)
|
||||
#define QT_EXT_QNX_READDIR_R ::_readdir_r
|
||||
#endif
|
||||
|
||||
#define QT_SNPRINTF ::snprintf
|
||||
#define QT_VSNPRINTF ::vsnprintf
|
||||
|
@ -83,8 +83,15 @@
|
||||
#include <arpa/inet.h>
|
||||
|
||||
#define QT_USE_XOPEN_LFS_EXTENSIONS
|
||||
#if !defined(__EXT_QNX__READDIR64_R)
|
||||
#define QT_NO_READDIR64
|
||||
#endif
|
||||
#include "../common/posix/qplatformdefs.h"
|
||||
#if defined(__EXT_QNX__READDIR64_R)
|
||||
#define QT_EXT_QNX_READDIR_R ::_readdir64_r
|
||||
#elif defined(__EXT_QNX__READDIR_R)
|
||||
#define QT_EXT_QNX_READDIR_R ::_readdir_r
|
||||
#endif
|
||||
|
||||
#define QT_SNPRINTF ::snprintf
|
||||
#define QT_VSNPRINTF ::vsnprintf
|
||||
|
@ -105,8 +105,8 @@ bool QFileSystemIterator::advance(QFileSystemEntry &fileEntry, QFileSystemMetaDa
|
||||
if (!dir)
|
||||
return false;
|
||||
|
||||
#if defined(Q_OS_QNX) && defined(__EXT_QNX__READDIR_R)
|
||||
lastError = _readdir_r(dir, mt_file.data(), &dirEntry, direntSize);
|
||||
#if defined(Q_OS_QNX) && defined(QT_EXT_QNX_READDIR_R)
|
||||
lastError = QT_EXT_QNX_READDIR_R(dir, mt_file.data(), &dirEntry, direntSize);
|
||||
if (lastError)
|
||||
return false;
|
||||
#elif defined(_POSIX_THREAD_SAFE_FUNCTIONS) && !defined(Q_OS_CYGWIN)
|
||||
|
Loading…
Reference in New Issue
Block a user