Skip to content

cliinterface: adapt to behavior change in QTemporaryDir

Elvis Angelaccio requested to merge work/bug-487229 into master

Qt 6.7 changed the behavior of QTemporaryDir (see commit 935562a77b in qtbase.git) and now QTemporaryDir::path() returns a relative path rather than an absolute one.

We were relying on the old behavior which ensured that the extract temp dir would always auto-delete itself, regardless of the ark CWD.

This is no longer working, because now when the temp dir gets deleted, its destructor tries to delete a relative path, but meanwhile ark has already changed the CWD and so that path does not exist.

The fix is to create the QTemporaryDir with an absolute path (but still as hidden folder in the CWD), so we get back the old behavior (the returned QTemporaryDir::path() will again be absolute).

BUG: 487229

Merge request reports