ipv4.h 576 B

123456789101112131415161718192021
  1. /* Copyright (c) 2003-2004, Roger Dingledine
  2. * Copyright (c) 2004-2006, Roger Dingledine, Nick Mathewson.
  3. * Copyright (c) 2007-2018, The Tor Project, Inc. */
  4. /* See LICENSE for licensing information */
  5. /**
  6. * \file ipv4.h
  7. * \brief Header for ipv4.c
  8. **/
  9. #ifndef TOR_IPV4_H
  10. #define TOR_IPV4_H
  11. #include <stddef.h>
  12. struct in_addr;
  13. int tor_inet_aton(const char *str, struct in_addr *addr);
  14. /** Length of a buffer to allocate to hold the results of tor_inet_ntoa.*/
  15. #define INET_NTOA_BUF_LEN 16
  16. int tor_inet_ntoa(const struct in_addr *in, char *buf, size_t buf_len);
  17. #endif