Qt Base (Core, Gui, Widgets, Network, ...)
Go to file
Thiago Macieira 35dbd1c3f4 QFileSystemEngine/Unix: work around FreeBSD bug in copy_file_range(2)
Amends commit 9b006eb91a, which introduced
the use of this function. When I tested this with FreeBSD 14.2, this
code worked; now with 14.3 it doesn't, because on output the srcoffset
and dstoffset variables are still zero, in spite of having copied
content. That caused the copy_file_range() loop to copy the same files
over and over again, never exiting.

I've tracked this down to a change in 14.3[1] which showed that if both
inoffp and outoffp were non-NULL, it wouldn't update. FreeBSD
maintainers report this is already fixed[2] and will be made available
soon.

tst_qfile now passes again on FreeBSD.

strace output on Linux:
ioctl(5, BTRFS_IOC_CLONE or FICLONE, 4) = -1 EOPNOTSUPP (Operation not supported)
copy_file_range(4, [0], 5, NULL, 9223372036854775807, 0) = 13587
copy_file_range(4, [13587], 5, NULL, 9223372036854775807, 0) = 0

truss output on FreeBSD:
copy_file_range(0x4,0x32fb9588e360,0x5,0x0,0x7fffffffffffffff,0x0) = 624 (0x270)
copy_file_range(0x4,0x32fb9588e360,0x5,0x0,0x7fffffffffffffff,0x0) = 0 (0x0)

No changelog because the content is new in 6.10.

[1] 1d2fd8c9cf
[2] 4046ad6bb0

Pick-to: 6.10
Fixes: QTBUG-138570
Change-Id: I31ddcefb63bb738f0cc0fffd75d9f68030952ed5
Reviewed-by: Ahmad Samir <a.samirh78@gmail.com>
2025-08-22 06:42:42 +00:00
.github/workflows
LICENSES
bin
cmake CMake: Conditionally generate SPDX fields if value is not given 2025-08-21 16:26:01 +02:00
coin Introduce UseToolchainFromTargetDir feature for tests that are built at test stage 2025-08-20 16:34:18 +02:00
config.tests
dist Remove year from Qt Copyright in REUSE.toml 2025-07-09 15:16:21 +02:00
doc Doc: Update section title in app examples template 2025-08-21 18:31:21 +02:00
examples ImageGestures example: decide direction based on swipeAngle 2025-08-01 01:14:13 +02:00
lib
libexec qt-android-runner.py: handle all possible Gradle namespace formats 2025-08-01 23:24:14 +03:00
mkspecs qmake: Make ccache feature available on windows hosts 2025-08-15 15:19:50 +02:00
qmake Fail builds on Apple platforms with invalid Info.plist 2025-07-04 15:02:22 +02:00
src QFileSystemEngine/Unix: work around FreeBSD bug in copy_file_range(2) 2025-08-22 06:42:42 +00:00
tests tst_QImage: Resolve image format name via QDebug::toBytes() 2025-08-21 18:22:45 +02:00
util QChar::isSpace: optimize by lowering the upper limit check 2025-08-19 18:04:55 -07:00
.cmake.conf Bump minimum requirement for visionOS to version 2 2025-06-20 15:25:11 +02:00
.gitattributes
.gitignore Fix .gitignore to ignore any build dir under the repo or its subdirs 2025-07-22 19:12:39 +00:00
.gitreview
.tag
CMakeLists.txt
REUSE.toml CMake: support reduced relocations for namespaced Qt 2025-08-14 05:52:37 +08:00
config_help.txt Make doc-snippets a "build part", ie -nomake/make doc-snippets 2025-07-30 16:01:51 +02:00
configure
configure.bat
configure.cmake CMake: detect an ELF-based system using the feature support 2025-08-14 11:37:55 -07:00
dependencies.yaml
licenseRule.json CMake: support reduced relocations for namespaced Qt 2025-08-14 05:52:37 +08:00
qt_cmdline.cmake Make doc-snippets a "build part", ie -nomake/make doc-snippets 2025-07-30 16:01:51 +02:00