From b486ec66eddb35e4f8b7a499a76118f7e60c92dd Mon Sep 17 00:00:00 2001 From: vijay-jaisankar Date: Thu, 19 May 2022 01:47:06 +0530 Subject: [PATCH] bugfix: fixed import errors --- oclfile.py | 4 ++-- oclprocess.py | 6 ++++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/oclfile.py b/oclfile.py index 2a3c2749..7f7795d1 100644 --- a/oclfile.py +++ b/oclfile.py @@ -67,7 +67,7 @@ def getLocalAddress(self) : def getPort(self) : return self.port - def getLocalPort() : + def getLocalPort(self) : return self.port def compareTo(self,f) : @@ -344,7 +344,7 @@ def readN(self,n) : self.position = self.position + 1 res.append(s) ind = ind + 1 - except Error : + except Exception as e : self.eof = True self.lastRead = None break diff --git a/oclprocess.py b/oclprocess.py index 258b7a34..83452578 100644 --- a/oclprocess.py +++ b/oclprocess.py @@ -1,5 +1,7 @@ import threading import time +import ocl +import oclfile class OclProcess: oclprocess_instances = [] @@ -52,7 +54,7 @@ def setName(self,nme) : self.name = nme if self.actualThread != None : self.actualThread.name = nme - return result + def getPriority(self) : return self.priority @@ -89,7 +91,7 @@ def interrupt(self) : def killOclProcess(oclprocess_x) : oclprocess_instances = ocl.excludingSet(oclprocess_instances, oclprocess_x) - free(oclprocess_x) + oclfile.free(oclprocess_x) def createOclProcess(): oclprocess = OclProcess()