D20096: Fill UDSEntry::UDS_CREATION_TIME under linux when glibc >= 2.28

Fabian Vogt noreply at phabricator.kde.org
Sun Mar 31 11:16:11 BST 2019


fvogt added a comment.


  In D20096#440842 <https://phabricator.kde.org/D20096#440842>, @meven wrote:
  
  > In D20096#440830 <https://phabricator.kde.org/D20096#440830>, @pino wrote:
  >
  > > Note that, even if the system supports statx() (so with glibc >= 2.28), you must support systems without it at runtime anyway: for example, if you boot with a kernel older than 4.11 (which IIRC is the version where the syscall was added) then the glibc function will return ENOSYS (IIRC, better check). This can happen for example in containers: you boot a Debian testing container (so with glibc 2.28) on a Debian stable system (with Linux 4.9).
  >
  >
  > This case is covered by glibc https://github.com/lattera/glibc/blob/895ef79e04a953cac1493863bcae29ad85657ee1/sysdeps/unix/sysv/linux/statx.c
  >  In case the syscall does not exist, glibc provides a generic implementation based on stat.
  
  
  There are platforms out there which don't use glibc. So I suggest either handling ENOSYS properly by falling back to stat or erroring out if statx is supported but __GLIBC__ not defined.
  
  > The code also takes into account that the birthtime field still depends on the filesystem used and this information can be missing even on ext4, line 1015. Although I haven't tested it.
  > 
  > Qt is adding support for statx in Qt 5.13 https://github.com/qt/qtbase/commit/d3393ce25833c0afd7f0fa6b85fd6f3bd7ad520a
  
  Qt already supports statx since 5.10 - the linked commit is part of the v5.10.0-alpha1 tag.

REPOSITORY
  R241 KIO

REVISION DETAIL
  https://phabricator.kde.org/D20096

To: meven, #frameworks, dfaure, fvogt, bruns, broulik
Cc: pino, bcooksley, ngraham, kde-frameworks-devel, michaelh, bruns
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20190331/226a58a1/attachment-0001.html>


More information about the Kde-frameworks-devel mailing list