Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork8.2k
Commit9ef16b4
committed
extmod/modjson: Detect unterminated composite entities.
This commit makes the JSON parser raise an exception when handlingobjects or arrays whose declaration is incomplete, as in missing theclosing marker (brace or bracket) and if the missing marker would havebeen the last non-whitespace character in the incoming string.Since CPython's JSON parser would raise an exception in such a case,unlike MicroPython's, this commit aligns MicroPython's behaviour withCPython.This commit fixes issue#17141.Signed-off-by: Alessandro Gatti <a.gatti@frob.it>1 parent7a55cb6 commit9ef16b4
2 files changed
+26
-1
lines changedLines changed: 2 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
160 | 160 |
| |
161 | 161 |
| |
162 | 162 |
| |
163 |
| - | |
| 163 | + | |
| 164 | + | |
164 | 165 |
| |
165 | 166 |
| |
166 | 167 |
| |
|
Lines changed: 24 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
71 | 71 |
| |
72 | 72 |
| |
73 | 73 |
| |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + |
0 commit comments
Comments
(0)