Commit 36d35345b1f6124d7e1763c818ec29e1709f9eec
Committed by
Tom Rini
1 parent
2d5e86b110
Exists in
smarc_8mq_lf_v2020.04
and in
17 other branches
tpm: add missing va_end
va_start must always be matched by va_end. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Reviewed-by: Simon Glass <sjg@chromium.org>
Showing 1 changed file with 4 additions and 1 deletions Side-by-side Diff
lib/tpm.c
... | ... | @@ -95,8 +95,10 @@ |
95 | 95 | return -1; |
96 | 96 | } |
97 | 97 | |
98 | - if (offset + length > size) | |
98 | + if (offset + length > size) { | |
99 | + va_end(args); | |
99 | 100 | return -1; |
101 | + } | |
100 | 102 | |
101 | 103 | switch (*format) { |
102 | 104 | case 'b': |
... | ... | @@ -163,6 +165,7 @@ |
163 | 165 | length = va_arg(args, uint32_t); |
164 | 166 | break; |
165 | 167 | default: |
168 | + va_end(args); | |
166 | 169 | debug("Couldn't recognize format string\n"); |
167 | 170 | return -1; |
168 | 171 | } |
-
mentioned in commit 9d0c5f
-
mentioned in commit 9d0c5f
-
mentioned in commit 9d0c5f
-
mentioned in commit 9d0c5f
-
mentioned in commit 9d0c5f
-
mentioned in commit 9d0c5f
-
mentioned in commit 9d0c5f
-
mentioned in commit 9d0c5f
-
mentioned in commit 9d0c5f
-
mentioned in commit 9d0c5f
-
mentioned in commit 9d0c5f
-
mentioned in commit 9d0c5f
-
mentioned in commit 9d0c5f
-
mentioned in commit 9d0c5f
-
mentioned in commit 9d0c5f
-
mentioned in commit 9d0c5f
-
mentioned in commit 9d0c5f
-
mentioned in commit 9d0c5f
-
mentioned in commit 9d0c5f
-
mentioned in commit 9d0c5f