Skip to content

Commit f083c1e

Browse files
committed
Wait for display setup script no more than 30s
Kill the script if it takes long.
1 parent 7ed4ab1 commit f083c1e

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/daemon/XorgDisplayServer.cpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -290,7 +290,10 @@ namespace SDDM {
290290
// start display setup script
291291
qDebug() << "Running display setup script " << displayCommand;
292292
displayScript->start(displayCommand);
293-
displayScript->waitForFinished(-1);
293+
294+
// wait for finished
295+
if (!displayScript->waitForFinished(30000))
296+
displayScript->kill();
294297
}
295298

296299
void XorgDisplayServer::changeOwner(const QString &fileName) {

0 commit comments

Comments
 (0)