Repository navigation
Commit 8045934
tests: copy the resolver address pointer out
build_addr() copies the pointer out of entry->h_addr_list with memcpy
before dereferencing it. The resolver's array is not pointer aligned on
macOS, so loading the char* in place is undefined behavior and UBSan
flags it on any run that reaches the gethostbyname() path.1 parent 8a0c7a9 commit 8045934
1 file changed
Lines changed: 5 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
504 | 504 | | |
505 | 505 | | |
506 | 506 | | |
507 | | - | |
508 | | - | |
| 507 | + | |
| 508 | + | |
| 509 | + | |
| 510 | + | |
| 511 | + | |
509 | 512 | | |
510 | 513 | | |
511 | 514 | | |
| |||
0 commit comments