parses the specified `spec` and returns an associated * socket_info*, if it could be found */
| 552 | /* parses the specified `spec` and returns an associated |
| 553 | * socket_info*, if it could be found */ |
| 554 | const struct socket_info* parse_sock_info(str *addr) |
| 555 | { |
| 556 | int port, proto; |
| 557 | str host; |
| 558 | |
| 559 | if (!addr || !addr->s) |
| 560 | return NULL; |
| 561 | |
| 562 | if (parse_phostport(addr->s, addr->len, &host.s, &host.len, |
| 563 | &port, &proto) != 0) { |
| 564 | return NULL; |
| 565 | } |
| 566 | |
| 567 | return grep_internal_sock_info(&host, (unsigned short) port, |
| 568 | (unsigned short) proto); |
| 569 | } |
| 570 | |
| 571 | struct socket_info_full* grep_sock_by_orig_name(unsigned short proto, str *host, |
| 572 | unsigned short port, struct socket_info_full *resume) |
no test coverage detected