Commit bc4915c
committed
sqlite: throw on oversized error messages
SQLite error messages embed the offending identifier or token, so they
can exceed String::kMaxLength. CreateSQLiteErrorImpl() converted them
with String::NewFromUtf8() and the default length of -1, which skips
V8's length check and aborts the process.
Convert the message with Utf8StringMaybeOneByte() so an oversized
message throws ERR_STRING_TOO_LONG instead.
Signed-off-by: Trivikram Kamat <16024985+trivikr@users.noreply.github.com>
Assisted-by: claude:opus-5.51 parent 85df70e commit bc4915c
2 files changed
Lines changed: 12 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
284 | 284 | | |
285 | 285 | | |
286 | 286 | | |
287 | | - | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
288 | 290 | | |
289 | 291 | | |
290 | 292 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1458 | 1458 | | |
1459 | 1459 | | |
1460 | 1460 | | |
| 1461 | + | |
| 1462 | + | |
| 1463 | + | |
| 1464 | + | |
| 1465 | + | |
| 1466 | + | |
| 1467 | + | |
| 1468 | + | |
| 1469 | + | |
1461 | 1470 | | |
1462 | 1471 | | |
1463 | 1472 | | |
| |||
0 commit comments