mirror of
https://github.com/Mbed-TLS/mbedtls-framework.git
synced 2026-10-26 10:13:31 +00:00
scripts: ssl_session_reset_check: return exception if parsing of preprocessor directive fails
If next(lines) return StopIteration while processing a preprocessor directive then that's an expected failure that should be reported to the user. Signed-off-by: Valerio Setti <[email protected]>
This commit is contained in:
@@ -183,7 +183,8 @@ class CStruct:
|
||||
try:
|
||||
argument = argument[:-1] + ' ' + next(lines)[1]
|
||||
except StopIteration:
|
||||
break
|
||||
raise Exception(f'Unexpected end of the structure reached while '
|
||||
' parsing a C preprocessor directive')
|
||||
return argument
|
||||
|
||||
def _structure_fields(self,
|
||||
|
||||
Reference in New Issue
Block a user