forked from mindspore-Ecosystem/mindspore
!17502 fix report error if the length of hwts data is less than 64
From: @yanghaitao1 Reviewed-by: @yelihua,@ouwenchang Signed-off-by: @ouwenchang
This commit is contained in:
commit
4729bb1c58
|
@ -77,6 +77,9 @@ class HWTSLogParser:
|
|||
if line:
|
||||
if not line.strip():
|
||||
continue
|
||||
if len(line) < 64:
|
||||
logger.warning("Length of hwts data is less than 64")
|
||||
continue
|
||||
else:
|
||||
break
|
||||
byte_first_four = struct.unpack('BBHHH', line[0:8])
|
||||
|
|
Loading…
Reference in New Issue