Utils: Remove toFSPathString from FilePath::createTempFile

QTemporaryFile only works with local files.

Change-Id: Iafa8c252e7b3cc2d00f6a3cef33823db4ac4808a
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Andrii Semkiv <andrii.semkiv@qt.io>
This commit is contained in:
Marcus Tillmanns
2024-09-10 14:12:52 +02:00
parent 218a8b7787
commit 6a06901d8f

View File

@@ -600,7 +600,7 @@ expected_str<FilePath> FilePath::tmpDir() const
expected_str<FilePath> FilePath::createTempFile() const expected_str<FilePath> FilePath::createTempFile() const
{ {
if (!needsDevice()) { if (!needsDevice()) {
QTemporaryFile file(toFSPathString()); QTemporaryFile file(path());
file.setAutoRemove(false); file.setAutoRemove(false);
if (file.open()) if (file.open())
return FilePath::fromString(file.fileName()); return FilePath::fromString(file.fileName());