mirror of
https://opendev.org/x/pyghmi
synced 2025-07-24 13:11:11 +00:00
Remove NUL bytes from SMM serial/model
The data may contain NUL bytes, make sure strip removes them. Change-Id: I3bfea4ac85fb696e30a6b990e9fa167b4005edab
This commit is contained in:
@@ -243,11 +243,11 @@ class SMMClient(object):
|
||||
def process_fru(self, fru):
|
||||
# TODO(jjohnson2): can also get EIOM, SMM, and riser data if warranted
|
||||
fru['Serial Number'] = self.ipmicmd.xraw_command(
|
||||
netfn=0x32, command=0xb0, data=(5, 1))['data'][:].strip().replace(
|
||||
'\xff', '')
|
||||
netfn=0x32, command=0xb0, data=(5, 1))['data'][:].strip(
|
||||
' \x00\xff').replace('\xff', '')
|
||||
fru['Model'] = self.ipmicmd.xraw_command(
|
||||
netfn=0x32, command=0xb0, data=(5, 0))['data'][:].strip().replace(
|
||||
'\xff', '')
|
||||
netfn=0x32, command=0xb0, data=(5, 0))['data'][:].strip(
|
||||
' \x00\xff').replace('\xff', '')
|
||||
return fru
|
||||
|
||||
def get_webclient(self):
|
||||
|
Reference in New Issue
Block a user