Sun, 24 Dec 2017 15:19:00 +0100
Fixed an issue in the debug client causing it to enter an inifinite loop if the frontend crashed.
--- a/DebugClients/Python/DebugClientBase.py Sat Dec 23 16:42:21 2017 +0100 +++ b/DebugClients/Python/DebugClientBase.py Sun Dec 24 15:19:00 2017 +0100 @@ -1014,19 +1014,24 @@ Public method called when there is data ready to be read. @param stream file like object that has data to be written + @return flag indicating an error condition + @rtype bool """ + error = False + + self.lockClient() try: - self.lockClient() command = stream.readCommand() - self.unlockClient() except Exception: - return + error = True + self.unlockClient() - if len(command) == 0: + if len(command) == 0 or error: self.sessionClose() - return + else: + self.handleJsonCommand(command) - self.handleJsonCommand(command) + return error def writeReady(self, stream): """ @@ -1079,7 +1084,9 @@ continue if self.readstream in rrdy: - self.readReady(self.readstream) + error = self.readReady(self.readstream) + if error: + break if self.writestream in wrdy: self.writeReady(self.writestream)
--- a/Documentation/Source/eric6.DebugClients.Python.DebugClientBase.html Sat Dec 23 16:42:21 2017 +0100 +++ b/Documentation/Source/eric6.DebugClients.Python.DebugClientBase.html Sun Dec 24 15:19:00 2017 +0100 @@ -688,6 +688,16 @@ <dd> file like object that has data to be written </dd> +</dl><dl> +<dt>Returns:</dt> +<dd> +flag indicating an error condition +</dd> +</dl><dl> +<dt>Return Type:</dt> +<dd> +bool +</dd> </dl><a NAME="DebugClientBase.run_call" ID="DebugClientBase.run_call"></a> <h4>DebugClientBase.run_call</h4> <b>run_call</b>(<i>scriptname, func, *args</i>)