[education/rkward] rkward/rbackend: Experimental: Does the Windows startup workaround fix the reported issue on RHEL as well?

Thomas Friedrichsmeier null at kde.org
Sun Jul 31 19:47:14 BST 2022


Git commit 5be22de34a70e443d13cfed0b13876a037164d64 by Thomas Friedrichsmeier.
Committed on 31/07/2022 at 18:46.
Pushed by tfry into branch 'master'.

Experimental: Does the Windows startup workaround fix the reported issue on RHEL as well?

M  +3    -4    rkward/rbackend/rkfrontendtransmitter.cpp

https://invent.kde.org/education/rkward/commit/5be22de34a70e443d13cfed0b13876a037164d64

diff --git a/rkward/rbackend/rkfrontendtransmitter.cpp b/rkward/rbackend/rkfrontendtransmitter.cpp
index 2ef4a788..2142adc7 100644
--- a/rkward/rbackend/rkfrontendtransmitter.cpp
+++ b/rkward/rbackend/rkfrontendtransmitter.cpp
@@ -130,17 +130,16 @@ void RKFrontendTransmitter::run () {
 	RK_DEBUG(RBACKEND, DL_INFO, "Setting working directory to %s", qPrintable (r_home));
 	backend->setWorkingDirectory (r_home);
 #endif
-#if defined(Q_OS_WIN)
-	// added on a hunch, to be removed, should it have no effect, to be cleaned, otherwise:
+//#if defined(Q_OS_WIN)
 	// On some windows systems, the _first_ invocation of the backend seems to fail as somehow process output from the backend (the token) never arrives.
-	// Could it help to start a dummy process, before that? And, if doing so, will we be able to read its output?
+	// What appears to function as a workaround is start a dummy process, before that.
 	QProcess dummy;
 	QStringList dummyargs = args;
 	dummyargs.removeAt(dummyargs.size()-4); // the --server-name. With this empty, the backend will exit
 	dummy.start(RKSessionVars::RBinary(), dummyargs, QIODevice::ReadOnly);
 	dummy.waitForFinished();
 	dummy.readAllStandardOutput();
-#endif
+//#endif
 	RK_DEBUG(RBACKEND, DL_DEBUG, "Starting backend. Timestamp %d", QDateTime::currentMSecsSinceEpoch(), token.length());
 	backend->start(RKSessionVars::RBinary(), args, QIODevice::ReadOnly);
 


More information about the rkward-tracker mailing list