[netperf-dev] netperf2 commit notice r108 - trunk/src

raj at netperf.org raj at netperf.org
Wed Apr 25 12:57:14 PDT 2007


Author: raj
Date: 2007-04-25 12:57:13 -0700 (Wed, 25 Apr 2007)
New Revision: 108

Modified:
   trunk/src/netlib.c
   trunk/src/nettest_sdp.c
Log:
tweaks

Modified: trunk/src/netlib.c
===================================================================
--- trunk/src/netlib.c	2007-04-25 19:34:20 UTC (rev 107)
+++ trunk/src/netlib.c	2007-04-25 19:57:13 UTC (rev 108)
@@ -471,6 +471,12 @@
   }
 }
 
+/* one of these days, this should not be required */
+#ifndef AF_INET_SDP
+#define AF_INET_SDP 27
+#define PF_INET_SDP AF_INET_SDP
+#endif 
+
 char *
 inet_ftos(int family) 
 {
@@ -483,6 +489,11 @@
     return("AF_INET6");
     break;
 #endif
+#if defined(AF_INET_SDP)
+  case AF_INET_SDP:
+    return("AF_INET_SDP");
+    break;
+#endif
   default:
     return("AF_UNSPEC");
   }

Modified: trunk/src/nettest_sdp.c
===================================================================
--- trunk/src/nettest_sdp.c	2007-04-25 19:34:20 UTC (rev 107)
+++ trunk/src/nettest_sdp.c	2007-04-25 19:57:13 UTC (rev 108)
@@ -283,6 +283,7 @@
     /*set up the data socket                        */
     /* fake things out by changing local_res->ai_family to AF_INET_SDP */
     local_res->ai_family = AF_INET_SDP;
+    local_res->ai_protocol = 0;
     send_socket = create_data_socket(local_res);
     
     if (send_socket == INVALID_SOCKET){
@@ -979,6 +980,7 @@
     /*set up the data socket                        */
     /* fake things out by changing local_res->ai_family to AF_INET_SDP */
     local_res->ai_family = AF_INET_SDP;
+    local_res->ai_protocol = 0;
     recv_socket = create_data_socket(local_res);
     
     if (recv_socket == INVALID_SOCKET){
@@ -1654,6 +1656,7 @@
 
   /* fake things out by changing local_res->ai_family to AF_INET_SDP */
   local_res->ai_family = AF_INET_SDP;
+  local_res->ai_protocol = 0;
   s_listen = create_data_socket(local_res);
   
   if (s_listen == INVALID_SOCKET) {
@@ -1988,6 +1991,7 @@
 
   /* fake things out by changing local_res->ai_family to AF_INET_SDP */
   local_res->ai_family = AF_INET_SDP;
+  local_res->ai_protocol = 0;
   s_listen = create_data_socket(local_res);
   
   if (s_listen == INVALID_SOCKET) {
@@ -2420,6 +2424,7 @@
     /*set up the data socket                        */
     /* fake things out by changing local_res->ai_family to AF_INET_SDP */
     local_res->ai_family = AF_INET_SDP;
+    local_res->ai_protocol = 0;
     send_socket = create_data_socket(local_res);
   
     if (send_socket == INVALID_SOCKET){
@@ -3091,6 +3096,7 @@
 
   /* fake things out by changing local_res->ai_family to AF_INET_SDP */
   local_res->ai_family = AF_INET_SDP;
+  local_res->ai_protocol = 0;
   s_listen = create_data_socket(local_res);
   
   if (s_listen == INVALID_SOCKET) {



More information about the netperf-dev mailing list