Skip to content

Commit c4143f9

Browse files
kreuzbergerursfassler
authored andcommitted
add pid and app name to temp file template
1 parent ad5ad6c commit c4143f9

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

src/drivers/QtTestDriver.cpp

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,15 @@ namespace internal {
1515
class TemporaryFileWrapper {
1616
public:
1717
static TemporaryFileWrapper create() {
18-
QTemporaryFile tempFile{};
18+
QTemporaryFile tempFile(
19+
QString("%1/%2_%3")
20+
.arg(
21+
QDir::tempPath(),
22+
qApp->applicationName().isEmpty() ? "qt_temp"
23+
: qApp->applicationName()
24+
)
25+
.arg(qApp->applicationPid())
26+
);
1927

2028
if (!tempFile.open()) {
2129
return {};

0 commit comments

Comments
 (0)