mirror of
				https://github.com/xcat2/confluent.git
				synced 2025-10-31 11:22:28 +00:00 
			
		
		
		
	Fix ping before connection error
If ping() was called before connect, an exception was raised. Fix this by returning false in such an event.
This commit is contained in:
		| @@ -275,10 +275,13 @@ class IpmiConsole(conapi.Console): | ||||
|         self.solconnection.send_break() | ||||
|  | ||||
|     def ping(self): | ||||
|         if not self.solconnection: | ||||
|             return False | ||||
|         rsp = self.solconnection.ipmi_session.raw_command(netfn=6, | ||||
|                                                           command=0x4b, | ||||
|                                                           data=(1, 1)) | ||||
|         self.solconnection._got_payload_instance_info(rsp) | ||||
|         return True | ||||
|  | ||||
|  | ||||
| def perform_requests(operator, nodes, element, cfg, inputdata): | ||||
|   | ||||
		Reference in New Issue
	
	Block a user