Commit c2dd895
committed
transports: http: check for memory allocation failures
When allocating a chunk that is used to write to HTTP streams, we do not
check for memory allocation errors. This may lead us to write to a
`NULL` pointer and thus cause a segfault.
Fix this by adding a call to `GIT_ERROR_CHECK_ALLOC`.1 parent 0869954 commit c2dd895
2 files changed
+7
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1337 | 1337 | | |
1338 | 1338 | | |
1339 | 1339 | | |
1340 | | - | |
| 1340 | + | |
1341 | 1341 | | |
| 1342 | + | |
| 1343 | + | |
1342 | 1344 | | |
1343 | 1345 | | |
1344 | 1346 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1011 | 1011 | | |
1012 | 1012 | | |
1013 | 1013 | | |
| 1014 | + | |
1014 | 1015 | | |
1015 | 1016 | | |
1016 | 1017 | | |
| |||
1392 | 1393 | | |
1393 | 1394 | | |
1394 | 1395 | | |
1395 | | - | |
| 1396 | + | |
1396 | 1397 | | |
| 1398 | + | |
| 1399 | + | |
1397 | 1400 | | |
1398 | 1401 | | |
1399 | 1402 | | |
| |||
0 commit comments