aboutsummaryrefslogtreecommitdiffstats
path: root/wsutil/inet_addr.c
AgeCommit message (Collapse)AuthorFilesLines
2018-05-28wsutil: fix compilation on freebsd.Dario Lombardo1-0/+4
Change-Id: Iadb3f3daa1095ac9cc971f79ba4d288e8d835a44 Reviewed-on: https://code.wireshark.org/review/27864 Petri-Dish: Dario Lombardo <lomato@gmail.com> Reviewed-by: Guy Harris <guy@alum.mit.edu>
2018-05-16Eliminate some unneeded header checks.Guy Harris1-2/+0
sys/stat.h and sys/types.h date back to V7 UNIX, so they should be present on all UN*Xes, and we're assuming they're available on Windows, so, unless and until we ever support platforms that are neither UN*Xes nor Windows, we don't need to check for them. Remove the CMake checks for them, remove the HAVE_ values from cmakeconfig.h.in, and remove all tests for the HAVE_ values. Change-Id: I90bb2aab37958553673b03b52f4931d3b304b9d0 Reviewed-on: https://code.wireshark.org/review/27603 Petri-Dish: Guy Harris <guy@alum.mit.edu> Tested-by: Petri Dish Buildbot Reviewed-by: Guy Harris <guy@alum.mit.edu>
2018-02-08replace SPDX identifier GPL-2.0+ with GPL-2.0-or-later.Dario Lombardo1-1/+1
The first is deprecated, as per https://spdx.org/licenses/. Change-Id: I8e21e1d32d09b8b94b93a2dc9fbdde5ffeba6bed Reviewed-on: https://code.wireshark.org/review/25661 Petri-Dish: Anders Broman <a.broman58@gmail.com> Petri-Dish: Dario Lombardo <lomato@gmail.com> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2017-12-10Convert to using use SPDX identifier on wsutil directoryMichael Mann1-13/+1
Change-Id: Id73e641499e75bc1afc1dea29682418156f461fe Reviewed-on: https://code.wireshark.org/review/24751 Petri-Dish: Michael Mann <mmann78@netscape.net> Tested-by: Petri Dish Buildbot Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-10-30Avoid asserting with EAFNOSUPPORTJoão Valverde1-9/+34
We require support for AF_INET/AF_INET6 to run and assume this is available on all supported platforms. If and when reality clashes with that assumption just avoid aborting. Errors are to be expected as long as they don't produce a crash. Change-Id: I5c107b1a8fd64441eb96f48381412e180b66feb7 Reviewed-on: https://code.wireshark.org/review/24187 Petri-Dish: João Valverde <j@v6e.pt> Tested-by: Petri Dish Buildbot Reviewed-by: João Valverde <j@v6e.pt>
2017-10-29Do not assert in ws_inet_ntop()João Valverde1-4/+12
Change-Id: I9d420c5f6bc29ce94855017739169dc8e8ce4d48 Reviewed-on: https://code.wireshark.org/review/24173 Petri-Dish: João Valverde <j@v6e.pt> Tested-by: Petri Dish Buildbot Reviewed-by: João Valverde <j@v6e.pt>
2017-10-26Improve our inet_ntop() wrapperJoão Valverde1-5/+17
Also fix buffer length define, as it is not guaranteed to be 46 on Windows (it never was guaranteed anyway for the libc implementation, but the likelyhood of being greater was small). Change-Id: I2db705d86f825765ed32ec70b8d22058b5d629e8 Reviewed-on: https://code.wireshark.org/review/24074 Reviewed-by: João Valverde <j@v6e.pt>
2017-10-26Add a ws_in6_addr typedef for struct e_in6_addr.Guy Harris1-1/+1
That allows a parallel typedef of ws_in4_addr for guint32. Change-Id: I03b230247065e0e3840eb87635315a8e523ef562 Reviewed-on: https://code.wireshark.org/review/24073 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2017-10-25Remove replacement inet_pton/inet_ntopJoão Valverde1-3/+20
Should be available on every platform we support. Change-Id: Ib65d78e351d22d581b427e5e93fc8d5e5348b260 Reviewed-on: https://code.wireshark.org/review/24047 Reviewed-by: Gerald Combs <gerald@wireshark.org> Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-12-02Make sure config.h is included before inet_addr.h.Guy Harris1-2/+2
Otherwise, _FILE_OFFSET_BITS might be defined by a header file included by inet_addr.h before it gets defined by config.h. Change-Id: I5987b3f1493b81fd2d427d9792b9606117b255d0 Reviewed-on: https://code.wireshark.org/review/19018 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-02-19Fix implicit conversion from 64 to 32 bitsJoão Valverde1-2/+2
Change size_t to something that is guaranteed to fit in a socklen_t. Fix incorrect AC_DEFINE too. Change-Id: I710f32fb1e5bd4f51843d380aa8ed8b6acd98c02 Reviewed-on: https://code.wireshark.org/review/14009 Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: João Valverde <j@v6e.pt>
2016-02-19Add inet_pton/inet_ntop interface to libwsutilJoão Valverde1-0/+60
Change-Id: Ifc344ed33f2f7ca09a6912a5adb49dc35f07c81f Reviewed-on: https://code.wireshark.org/review/13881 Petri-Dish: João Valverde <j@v6e.pt> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: João Valverde <j@v6e.pt>