when recvfrom prototype uses a void pointer for arguments 2, 5 or 6 this will
authorYang Tse <yangsita@gmail.com>
Mon, 21 Jul 2008 00:36:55 +0000 (00:36 +0000)
committerYang Tse <yangsita@gmail.com>
Mon, 21 Jul 2008 00:36:55 +0000 (00:36 +0000)
now cause the definition of RECVFROM_TYPE_ARG2_IS_VOID, RECVFROM_TYPE_ARG5_IS_VOID
or RECVFROM_TYPE_ARG6_IS_VOID, as appropriate.

CHANGES
Makefile.dj
Makefile.netware
acinclude.m4

diff --git a/CHANGES b/CHANGES
index 88662236ae2f215c4107facd822d8b170c417f87..b35a593d479ca1da2b4328e8acd05e3c8960eb0b 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,5 +1,10 @@
   Changelog for the c-ares project
 
+* Jul 20 2008 (Yang Tse)
+- when recvfrom prototype uses a void pointer for arguments 2, 5 or 6 this will
+  now cause the definition, as appropriate, of RECVFROM_TYPE_ARG2_IS_VOID,
+  RECVFROM_TYPE_ARG5_IS_VOID or RECVFROM_TYPE_ARG6_IS_VOID.
+
 * Jul 17 2008 (Yang Tse)
 - RECVFROM_TYPE_ARG2, RECVFROM_TYPE_ARG5 and RECVFROM_TYPE_ARG6 are now defined
   to the data type pointed by its respective argument and not the pointer type.
index 51439284b4034971cede1e0cbd4250e9af735fa4..dd20dc5422acb042c0d32b50bf0f95d85137c6a3 100644 (file)
@@ -27,7 +27,8 @@ CFLAGS += -DWATT32 -DHAVE_AF_INET6 -DHAVE_PF_INET6 -DHAVE_IOCTLSOCKET \
           -DRECVFROM_TYPE_ARG1='int' -DRECVFROM_TYPE_ARG2='void' \
           -DRECVFROM_TYPE_ARG3='int' -DRECVFROM_TYPE_ARG4='int' \
           -DRECVFROM_TYPE_ARG6='int' -DRECVFROM_TYPE_RETV='int' \
-          -DRECVFROM_TYPE_ARG5='struct sockaddr' -DHAVE_RECVFROM
+          -DRECVFROM_TYPE_ARG5='struct sockaddr' -DHAVE_RECVFROM \
+          -DRECVFROM_TYPE_ARG2_IS_VOID
 
 LDFLAGS = -s
 
index e8a8a26c5b1942e51b573e211f439dd11c2297d1..d82a9cd76aa36cfc70c8fe0eb77c287256e64b41 100644 (file)
@@ -338,6 +338,7 @@ else
        @echo $(DL)#define RECVFROM_TYPE_ARG5 struct sockaddr$(DL) >> $@
        @echo $(DL)#define RECVFROM_TYPE_ARG6 int$(DL) >> $@
        @echo $(DL)#define RECVFROM_TYPE_RETV ssize_t$(DL) >> $@
+       @echo $(DL)#define RECVFROM_TYPE_ARG2_IS_VOID 1$(DL) >> $@
        @echo $(DL)#define SEND_QUAL_ARG2$(DL) >> $@
        @echo $(DL)#define SEND_TYPE_ARG1 int$(DL) >> $@
        @echo $(DL)#define SEND_TYPE_ARG2 void *$(DL) >> $@
index 39154abfc4be1ca47b1c492cc800f00a130702f2..bea042ea8c86682b76f3e19e0dd88c6a2732fa0e 100644 (file)
@@ -1206,6 +1206,19 @@ AC_DEFUN([CURL_CHECK_FUNC_RECVFROM], [
       AC_DEFINE_UNQUOTED(RECVFROM_TYPE_ARG6, $recvfrom_type_arg6,
         [Define to the type pointed by arg 6 for recvfrom.])
       #
+      if test "$recvfrom_type_arg2" = "void"; then
+        AC_DEFINE_UNQUOTED(RECVFROM_TYPE_ARG2_IS_VOID, 1,
+          [Define to 1 if the type pointed by arg 2 for recvfrom is void.])
+      fi
+      if test "$recvfrom_type_arg5" = "void"; then
+        AC_DEFINE_UNQUOTED(RECVFROM_TYPE_ARG5_IS_VOID, 1,
+          [Define to 1 if the type pointed by arg 5 for recvfrom is void.])
+      fi
+      if test "$recvfrom_type_arg6" = "void"; then
+        AC_DEFINE_UNQUOTED(RECVFROM_TYPE_ARG6_IS_VOID, 1,
+          [Define to 1 if the type pointed by arg 6 for recvfrom is void.])
+      fi
+      #
       case $prev_sh_opts in
         *f*)
           ;;