Commit f37ffb7
s.hasert
Check success of mallocs + assign buf to NULL after free + moved free of buf under loop
- `malloc()` now gets checked for success. If they fail we goto cleanup.
- `buf` now gets assigned to `NULL` after being freed.
- `free()` of `buf` got moved immediately under loop that uses it.1 parent 3e89c13 commit f37ffb7
1 file changed
+7
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
494 | 494 | | |
495 | 495 | | |
496 | 496 | | |
| 497 | + | |
| 498 | + | |
| 499 | + | |
| 500 | + | |
497 | 501 | | |
498 | 502 | | |
499 | 503 | | |
| |||
511 | 515 | | |
512 | 516 | | |
513 | 517 | | |
| 518 | + | |
| 519 | + | |
| 520 | + | |
514 | 521 | | |
515 | 522 | | |
516 | 523 | | |
517 | 524 | | |
518 | | - | |
519 | | - | |
520 | 525 | | |
521 | 526 | | |
522 | 527 | | |
523 | | - | |
524 | 528 | | |
525 | 529 | | |
526 | 530 | | |
| |||
0 commit comments