ndt-dev - [ndt-dev] [ndt] r807 committed - Apply Richard/Dominic's web10g patch
Subject: NDT-DEV email list created
List archive
- From:
- To:
- Subject: [ndt-dev] [ndt] r807 committed - Apply Richard/Dominic's web10g patch
- Date: Tue, 09 Apr 2013 14:26:44 +0000
- Authentication-results: sfpop-ironport01.merit.edu; dkim=neutral (message not signed) header.i=none
Revision: 807
Author:
Date: Tue Apr 9 07:26:25 2013
Log: Apply Richard/Dominic's web10g patch
http://code.google.com/p/ndt/source/detail?r=807
Modified:
/branches/ndt-web10g/Applet/NDTConstants.java
/branches/ndt-web10g/Applet/Tcpbw100.java
/branches/ndt-web10g/configure.ac
/branches/ndt-web10g/src/Makefile.am
/branches/ndt-web10g/src/logging.c
/branches/ndt-web10g/src/logging.h
/branches/ndt-web10g/src/network.c
/branches/ndt-web10g/src/network.h
/branches/ndt-web10g/src/test_c2s_srv.c
/branches/ndt-web10g/src/test_meta_srv.c
/branches/ndt-web10g/src/test_mid_srv.c
/branches/ndt-web10g/src/test_results_clt.c
=======================================
--- /branches/ndt-web10g/Applet/NDTConstants.java Tue Apr 9 06:42:50
2013
+++ /branches/ndt-web10g/Applet/NDTConstants.java Tue Apr 9 07:26:25
2013
@@ -101,7 +101,22 @@
public static final int RFC_1323_DISABLED = 0;
public static final int RFC_1323_ENABLED = 1;
-
+ // Note Self disabled from servers standpoint i.e. disabled by server
+ public static final int RFC_1323_SELF_DISABLED = 2;
+ public static final int RFC_1323_PEER_DISABLED = 3;
+
+ // Section: RFC2018 SAck
+ public static final int RFC_2018_ENABLED = 1;
+
+ // Section: RFC2018 Nagle
+ public static final int RFC_896_ENABLED = 1;
+
+ // Section: RFC3168
+ public static final int RFC_3168_ENABLED = 1;
+ // Note Self disabled from servers standpoint i.e. disabled by server
+ public static final int RFC_3168_SELF_DISABLED = 2;
+ public static final int RFC_3168_PEER_DISABLED = 3;
+
// Section: Buffer limitation test thresholds
public static final float BUFFER_LIMITED = 0.15f; //unused right now
=======================================
--- /branches/ndt-web10g/Applet/Tcpbw100.java Tue Apr 9 06:42:50 2013
+++ /branches/ndt-web10g/Applet/Tcpbw100.java Tue Apr 9 07:26:25 2013
@@ -3379,35 +3379,35 @@
_txtStatistics.append("\n"
+
_resBundDisplayMsgs.getString("web100tcpOpts") + " \n");
_txtStatistics.append("RFC 2018 Selective Acknowledgment:
");
- if (_iSACKEnabled == iZero)
-
_txtStatistics.append(_resBundDisplayMsgs.getString("off")
+ if (_iSACKEnabled == NDTConstants.RFC_2018_Enabled)
+
_txtStatistics.append(_resBundDisplayMsgs.getString("on")
+ "\n");
else
-
_txtStatistics.append(_resBundDisplayMsgs.getString("on")
+
_txtStatistics.append(_resBundDisplayMsgs.getString("off")
+ "\n");
_txtStatistics.append("RFC 896 Nagle Algorithm: ");
- if (_iNagleEnabled == iZero)
-
_txtStatistics.append(_resBundDisplayMsgs.getString("off")
+ if (_iNagleEnabled == NDTConstants.RFC_896_ENABLED)
+
_txtStatistics.append(_resBundDisplayMsgs.getString("on")
+ "\n");
else
-
_txtStatistics.append(_resBundDisplayMsgs.getString("on")
+
_txtStatistics.append(_resBundDisplayMsgs.getString("off")
+ "\n");
_txtStatistics.append("RFC 3168 Explicit Congestion
Notification: ");
- if (_iECNEnabled == iZero)
-
_txtStatistics.append(_resBundDisplayMsgs.getString("off")
+ if (_iECNEnabled == NDTConstants.RFC_3168_ENABLED)
+
_txtStatistics.append(_resBundDisplayMsgs.getString("on")
+ "\n");
else
-
_txtStatistics.append(_resBundDisplayMsgs.getString("on")
+
_txtStatistics.append(_resBundDisplayMsgs.getString("off")
+ "\n");
_txtStatistics.append("RFC 1323 Time Stamping: ");
- if (_iTimestampsEnabled ==
NDTConstants.RFC_1323_DISABLED)
-
_txtStatistics.append(_resBundDisplayMsgs.getString("off")
+ if (_iTimestampsEnabled ==
NDTConstants.RFC_1323_ENABLED)
+
_txtStatistics.append(_resBundDisplayMsgs.getString("on")
+ "\n");
else
-
_txtStatistics.append(_resBundDisplayMsgs.getString("on")
+
_txtStatistics.append(_resBundDisplayMsgs.getString("off")
+ "\n");
_txtStatistics.append("RFC 1323 Window Scaling: ");
=======================================
--- /branches/ndt-web10g/configure.ac Tue Apr 9 07:17:33 2013
+++ /branches/ndt-web10g/configure.ac Tue Apr 9 07:26:25 2013
@@ -145,6 +145,18 @@
INCLUDED_WEB100LIB=""
AM_CONDITIONAL(HAVE_WEB100, false)
])
+AC_CHECK_LIB([tcpe], [tcpe_client_init],
+ [
+ LINKED_TCPELIB="-ltcpe"
+ INCLUDED_TCPELIB="-I/usr/local/include/tcpe"
+ AC_DEFINE(HAVE_LIBTCPE, 1, [Define to 1 if you have the 'Web10G' library (-ltcpe).])
+ AM_CONDITIONAL(HAVE_TCPE, true)
+ ],
+ [
+ LINKED_TCPELIB=""
+ INCLUDED_TCPELIB=""
+ AM_CONDITIONAL(HAVE_TCPE, false)
+ ])
AC_CHECK_LIB([pcap], [pcap_open_live],
[
@@ -197,14 +209,16 @@
])
-NDTINCDIR='$(INCLUDED_WEB100LIB) $(INCLUDED_PCAPLIB)'
+NDTINCDIR='$(INCLUDED_WEB100LIB) $(INCLUDED_PCAPLIB) $(INCLUDED_TCPELIB)'
NDTLIBDIR=/usr/local/lib
NDTLDFLAGS='-L$(NDTLIBDIR) -Wl,-rpath,$(NDTLIBDIR)'
-NDTLIBS='$(LINKED_WEB100LIB) $(LINKED_PCAPLIB) $(LINKED_ODBCLIB) -lm'
+NDTLIBS='$(LINKED_WEB100LIB) $(LINKED_PCAPLIB) $(LINKED_ODBCLIB) $(LINKED_TCPELIB) -lm'
NDTINCS='-I$(NDTINCDIR)'
AC_SUBST(LINKED_WEB100LIB)
AC_SUBST(INCLUDED_WEB100LIB)
+AC_SUBST(LINKED_TCPELIB)
+AC_SUBST(INCLUDED_TCPELIB)
AC_SUBST(LINKED_PCAPLIB)
AC_SUBST(INCLUDED_PCAPLIB)
AC_SUBST(LINKED_ODBCLIB)
@@ -275,6 +289,12 @@
echo ""
echo ""
+if test -z "$HAVE_TCPE_TRUE" && test -n "$HAVE_TCPE_FALSE"; then
+ SUMMARY_WEB10GSRV="YES"
+else
+ SUMMARY_WEB10GSRV="NO (missing tcpe (web10g) library)"
+fi
+
SUMMARY_WEB100CLT="YES"
if test -z "$HAVE_WEB100_TRUE" && test -n "$HAVE_WEB100_FALSE"; then
if test -z "$HAVE_PCAP_H_TRUE" && test -n "$HAVE_PCAP_H_FALSE"; then
@@ -314,13 +334,14 @@
echo "* web100clt: ${SUMMARY_WEB100CLT}"
echo ""
-if test "$SUMMARY_FAKEWWW" = "YES" && test "$SUMMARY_WEB100SRV" = "YES" && test "$SUMMARY_TCPBW100JAR" = "YES"; then
+if test "$SUMMARY_FAKEWWW" = "YES" && (test "$SUMMARY_WEB100SRV" = "YES" | | test "$SUMMARY_WEB100GSRV" = "YES") && test "$SUMMARY_TCPBW100JAR" = "YES"; then
echo "*** Server Tools - complete"
else
echo "*** Server Tools - incomplete"
fi
echo "* fakewww: ${SUMMARY_FAKEWWW}"
echo "* web100srv: ${SUMMARY_WEB100SRV}"
+echo "* web10gsrv: ${SUMMARY_WEB10GSRV}"
echo "* Tcpbw100.jar: ${SUMMARY_TCPBW100JAR}"
echo ""
=======================================
--- /branches/ndt-web10g/src/Makefile.am Wed Aug 8 13:32:32 2012
+++ /branches/ndt-web10g/src/Makefile.am Tue Apr 9 07:26:25 2013
@@ -33,6 +33,16 @@
bin_PROGRAMS = web100clt
endif
+if HAVE_TCPE
+if HAVE_PCAP_H
+if HAVE_WEB100
+sbin_PROGRAMS += web10gsrv
+else
+sbin_PROGRAMS = fakewww web10gsrv
+endif
+endif
+endif
+
web100clt_SOURCES = web100clt.c network.c usage.c logging.c utils.c protocol.c runningtest.c ndtptestconstants.c \
test_sfw_clt.c test_mid_clt.c test_c2s_clt.c test_s2c_clt.c test_meta_clt.c strlutils.c \
test_results_clt.c
@@ -46,7 +56,7 @@
analyze_SOURCES = analyze.c usage.c logging.c runningtest.c ndtptestconstants.c strlutils.c
analyze_LDADD = $(NDTLIBS) $(I2UTILLIBDEPS) $(ZLIB)
-analyze_CPPFLAGS ='-DBASEDIR="$(ndtdir)"'
+analyze_CPPFLAGS ='-DBASEDIR="$(ndtdir)"' -DFORCE_WEB100
fakewww_SOURCES = fakewww.c troute.c troute6.c tr-tree.c tr-tree6.c network.c usage.c logging.c \
runningtest.c ndtptestconstants.c strlutils.c
@@ -59,12 +69,21 @@
test_c2s_srv.c test_s2c_srv.c test_mid_srv.c
web100srv_LDFLAGS = $(NDTLDFLAGS) $(I2UTILLDFLAGS)
web100srv_LDADD = $(NDTLIBS) $(I2UTILLIBS) $(I2UTILLIBDEPS) -lpthread $(ZLIB)
-web100srv_CPPFLAGS ='-DBASEDIR="$(ndtdir)"'
+web100srv_CPPFLAGS ='-DBASEDIR="$(ndtdir)"' -DFORCE_WEB100
web100srv_DEPENDENCIES = $(I2UTILLIBDEPS)
+web10gsrv_SOURCES = web100srv.c web100-util.c web100-pcap.c web100-admin.c runningtest.c \
+ network.c usage.c utils.c mrange.c logging.c testoptions.c ndtptestconstants.c \
+ protocol.c test_sfw_srv.c test_meta_srv.c ndt_odbc.c strlutils.c heuristics.c \
+ test_c2s_srv.c test_s2c_srv.c test_mid_srv.c web10g-util.c
+web10gsrv_LDFLAGS = $(NDTLDFLAGS) $(I2UTILLDFLAGS)
+web10gsrv_LDADD = $(NDTLIBS) $(I2UTILLIBS) $(I2UTILLIBDEPS) -lpthread $(ZLIB)
+web10gsrv_CPPFLAGS = '-DBASEDIR="$(ndtdir)"'
+web10gsrv_DEPENDENCIES = $(I2UTILLIBDEPS)
+
viewtrace_SOURCES = viewtrace.c usage.c logging.c utils.c runningtest.c ndtptestconstants.c strlutils.c
viewtrace_LDADD = $(NDTLIBS) $(I2UTILLIBDEPS) $(ZLIB)
-viewtrace_CPPFLAGS ='-DBASEDIR="$(ndtdir)"'
+viewtrace_CPPFLAGS ='-DBASEDIR="$(ndtdir)"' -DFORCE_WEB100
tr_mkmap_SOURCES = tr-mkmap.c tr-tree.c tr-tree6.c usage.c logging.c runningtest.c ndtptestconstants.c strlutils.c
tr_mkmap_LDADD = $(NDTLIBS) $(I2UTILLIBDEPS) $(ZLIB)
=======================================
--- /branches/ndt-web10g/src/logging.c Mon Jan 7 09:51:37 2013
+++ /branches/ndt-web10g/src/logging.c Tue Apr 9 07:26:25 2013
@@ -701,7 +701,7 @@
* @param processid PID of process
* @param ctlSocket socket over which message has been exchanged
* */
-void protolog_sendprintln(const int type, void* msg, const int len,
+void protolog_sendprintln(const int type, const void* msg, const int len,
const int processid, const int ctlSocket) {
char *currentDir;
@@ -711,7 +711,7 @@
}
currentDir = get_currentdirndesc();
- protolog_println(currentDir, type, msg, len, processid, ctlSocket);
+ protolog_println(currentDir, type, (void*) msg, len, processid, ctlSocket);
}
/**
=======================================
--- /branches/ndt-web10g/src/logging.h Thu Nov 15 13:34:19 2012
+++ /branches/ndt-web10g/src/logging.h Tue Apr 9 07:26:25 2013
@@ -99,7 +99,7 @@
void protolog_printgeneric(const char* key, const char* val, int socketnum);
void protolog_status(int pid, enum TEST_ID testid,
enum TEST_STATUS_INT teststatus, int socketnum);
-void protolog_sendprintln(const int type, void* msg, const int len,
+void protolog_sendprintln(const int type, const void* msg, const int len,
const int processid, const int ctlSocket);
void protolog_rcvprintln(const int type, void* msg, const int len,
const int processid, const int ctlSocket);
=======================================
--- /branches/ndt-web10g/src/network.c Wed Mar 20 08:05:33 2013
+++ /branches/ndt-web10g/src/network.c Tue Apr 9 07:26:25 2013
@@ -415,7 +415,7 @@
*
*/
-int send_msg(int ctlSocket, int type, void* msg, int len) {
+int send_msg(int ctlSocket, int type, const void* msg, int len) {
unsigned char buff[3];
int rc, i;
@@ -524,9 +524,9 @@
* @return The amount of bytes written to the file descriptor
*/
-int writen(int fd, void* buf, int amount) {
+int writen(int fd, const void* buf, int amount) {
int sent, n;
- char* ptr = buf;
+ const char* ptr = buf;
sent = 0;
assert(amount >= 0);
while (sent < amount) {
=======================================
--- /branches/ndt-web10g/src/network.h Thu Nov 15 13:33:44 2012
+++ /branches/ndt-web10g/src/network.h Tue Apr 9 07:26:25 2013
@@ -20,9 +20,9 @@
I2Addr CreateListenSocket(I2Addr addr, char* serv, int options, int buf_size);
int CreateConnectSocket(int* sockfd, I2Addr local_addr, I2Addr server_addr,
int option, int buf_sizes);
-int send_msg(int ctlSocket, int type, void* msg, int len);
+int send_msg(int ctlSocket, int type, const void* msg, int len);
int recv_msg(int ctlSocket, int* type, void* msg, int* len);
-int writen(int fd, void* buf, int amount);
+int writen(int fd, const void* buf, int amount);
int readn(int fd, void* buf, int amount);
/* web100-util.c routine used in network. */
=======================================
--- /branches/ndt-web10g/src/test_c2s_srv.c Thu Nov 15 13:34:19 2012
+++ /branches/ndt-web10g/src/test_c2s_srv.c Tue Apr 9 07:26:25 2013
@@ -61,10 +61,13 @@
* -102 - Retries exceeded while waiting for data from
connected client
*
*/
-int test_c2s(int ctlsockfd, web100_agent* agent, TestOptions* testOptions,
+int test_c2s(int ctlsockfd, tcp_stat_agent* agent, TestOptions* testOptions,
int conn_options, double* c2sspd, int set_buff, int window,
int autotune, char* device, Options* options, int record_reverse,
int count_vars, char spds[4][256], int* spd_index) {
+ tcp_stat_connection conn;
+ tcp_stat_group* group = NULL;
+
int recvsfd; // receiver socket file descriptor
pid_t c2s_childpid = 0; // child process pids
int msgretvalue, tmpbytecount; // used during the "read"/"write" process
@@ -85,14 +88,12 @@
char listenc2sport[10]; // listening port
pthread_t workerThreadId;
- // web_100 related variables
- web100_group* group = NULL;
- web100_connection* conn = NULL;
-
// snap related variables
SnapArgs snapArgs;
snapArgs.snap = NULL;
+#if USE_WEB100
snapArgs.log = NULL;
+#endif
snapArgs.delay = options->snapDelay;
wait_sig = 0;
@@ -252,8 +253,8 @@
// commenting out below to move to init_pkttrace function
I2Addr src_addr = I2AddrByLocalSockFD(get_errhandle(), recvsfd, 0);
- // Get web100 connection. Used to collect web100 variable statistics
- conn = web100_connection_from_socket(agent, recvsfd);
+ // Get tcp_stat connection. Used to collect tcp_stat variable statistics
+ conn = tcp_stat_connection_from_socket(agent, recvsfd);
// set up packet tracing. Collected data is used for bottleneck link
// calculations
@@ -281,6 +282,7 @@
&cli_addr);
init_pkttrace(src_addr, (struct sockaddr *) &cli_addr, clilen,
mon_pipe1, device, &pair, "c2s", options->compress);
+ log_println(1, "c2s is exiting gracefully");
exit(0); /* Packet trace finished, terminate gracefully */
}
@@ -292,7 +294,7 @@
continue;
break;
}
- if (strlen(tmpstr) > 5)
+ //if (strlen(tmpstr) > 5)
memcpy(meta.c2s_ndttrace, tmpstr, strlen(tmpstr));
// name of nettrace file passed back from pcap child
log_println(3, "--tracefile after packet_trace %s",
@@ -375,13 +377,12 @@
// get receiver side Web100 stats and write them to the log file. close
// sockets
if (record_reverse == 1)
- web100_get_data_recv(recvsfd, agent, conn, count_vars);
-
- close(recvsfd);
- close(testOptions->c2ssockfd);
+ tcp_stat_get_data_recv(recvsfd, agent, conn, count_vars);
// Next, send speed-chk a flag to retrieve the data it collected.
// Skip this step if speed-chk isn't running.
+ close(recvsfd);
+ close(testOptions->c2ssockfd);
if (getuid() == 0) {
log_println(1, "Signal USR1(%d) sent to child [%d]", SIGUSR1,
=======================================
--- /branches/ndt-web10g/src/test_meta_srv.c Thu Nov 15 13:34:19 2012
+++ /branches/ndt-web10g/src/test_meta_srv.c Tue Apr 9 07:26:25 2013
@@ -22,7 +22,7 @@
/**
* Performs the META test.
* @param ctlsockfd Client control socket descriptor
- * @param agent Web100 agent used to track the connection
+ * @param agent UNUSED Web100 agent used to track the connection
* @param testOptions The test options
* @param conn_options The connection options
* @return 0 - success,
@@ -38,7 +38,7 @@
* 4 - Invalid data format in received message
*/
-int test_meta_srv(int ctlsockfd, web100_agent* agent, TestOptions* testOptions,
+int test_meta_srv(int ctlsockfd, tcp_stat_agent* agent, TestOptions* testOptions,
int conn_options) {
int j;
int msgLen, msgType;
=======================================
--- /branches/ndt-web10g/src/test_mid_srv.c Thu Nov 15 13:34:19 2012
+++ /branches/ndt-web10g/src/test_mid_srv.c Tue Apr 9 07:26:25 2013
@@ -9,7 +9,7 @@
* Author: kkumar
*/
-#include <syslog.h>
+#include <syslog.h>
#include <pthread.h>
#include <sys/times.h>
#include <assert.h>
@@ -37,7 +37,7 @@
* >0 - error code.
* Error codes:
* -1 - Listener socket creation failed
- * -3 - web100 connection data not obtained
+ * -3 - tcp_stat connection data not obtained
* -100 - timeout while waiting for client to connect to serverÕs ephemeral port
* -errno- Other specific socket error numbers
* -101 - Retries exceeded while waiting for
client to connect
@@ -49,7 +49,7 @@
*
*/
-int test_mid(int ctlsockfd, web100_agent* agent, TestOptions* options,
+int test_mid(int ctlsockfd, tcp_stat_agent* agent, TestOptions* options,
int conn_options, double* s2c_throughput_mid) {
int maxseg = ETHERNET_MTU_SIZE;
/* int maxseg=1456, largewin=16*1024*1024; */
@@ -66,7 +66,7 @@
char listenmidport[10]; // listener socket for middlebox tests
int msgType;
int msgLen;
- web100_connection* conn;
+ tcp_stat_connection conn;
char tmpstr[256]; // temporary string storage
struct timeval sel_tv; // time
fd_set rfd; // receiver file descriptor
@@ -235,8 +235,9 @@
meta.family = ((struct sockaddr *) &cli_addr)->sa_family;
buff[0] = '\0';
- // get web100 connection data
- if ((conn = web100_connection_from_socket(agent, midsfd)) == NULL) {
+ // get tcp_stat connection data
+#if USE_WEB100
+ if ((conn = tcp_stat_connection_from_socket(agent, midsfd)) == NULL) {
log_println(
0,
"!!!!!!!!!!! test_mid() failed to get web100 connection data, rc=%d",
@@ -244,9 +245,18 @@
/* exit(-1); */
return -3;
}
+#elif USE_TCPE
+ if ((conn = tcp_stat_connection_from_socket(agent, midsfd)) == -1) {
+ log_println(
+ 0,
+ "test_min() failed to get web10g connection data, rc=%d",
+ errno);
+ return -3;
+ }
+#endif
// Perform S->C throughput test. Obtained results in "buff"
- web100_middlebox(midsfd, agent, conn, buff, sizeof(buff));
+ tcp_stat_middlebox(midsfd, agent, conn, buff, sizeof(buff));
// Transmit results in the form of a TEST_MSG message
send_msg(ctlsockfd, TEST_MSG, buff, strlen(buff));
=======================================
--- /branches/ndt-web10g/src/test_results_clt.c Thu Jan 3 09:53:14 2013
+++ /branches/ndt-web10g/src/test_results_clt.c Tue Apr 9 07:26:25 2013
@@ -296,15 +296,27 @@
/**
* Print if TCP Selective Acknowledgment Options based on RFC 2018 is on
- *
+ * web100: 0 off, >=1 on.
+ * web10g: 1 on, 2 selfDisabled, 3 peerDisabled.
* @param SACKEnabled
*/
void print_SAck_RFC2018(int SACKEnabled) {
printf("RFC 2018 Selective Acknowledgment: ");
+#if USE_TCPE
+ if (SACKEnabled == 1)
+ printf("ON\n");
+ else if (SACKEnabled == 2)
+ printf("OFF (self)\n");
+ else if (SACKEnabled == 3)
+ printf("OFF (peer)\n");
+ else
+ printf("<undefined (%d)>\n", SACKEnabled);
+#elif USE_WEB100
if (SACKEnabled == 0)
printf("OFF\n");
else
printf("ON\n");
+#endif
}
/**
@@ -314,35 +326,69 @@
void print_Nagle_RFC896(int is_nagleenabled) {
printf("RFC 896 Nagle Algorithm: ");
+#if USE_TCPE
+ if (is_nagleenabled == 1)
+ printf("ON\n");
+ else if (is_nagleenabled == 2)
+ printf("OFF\n");
+ else
+ printf("<undefined (%d)>\n", is_nagleenabled);
+#elif USE_WEB100
if (is_nagleenabled == 0)
printf("OFF\n");
else
printf("ON\n");
+#endif
}
/**
* Print if Explicit congestion notification to IP is on - RFC 3168 related
+ * web100 0 off, >=1 on
+ * web10g 1 on, 2 selfDisabled, 3 peerDisabled
* @param is_ECNenabled
*/
void print_congestion_RFC3168(int is_ECNenabled) {
printf("RFC 3168 Explicit Congestion Notification: ");
+#if USE_TCPE
+ if (is_ECNenabled == 1)
+ printf("ON\n");
+ else if (is_ECNenabled == 2)
+ printf("OFF (self)\n");
+ else if (is_ECNenabled == 3)
+ printf("OFF (peer)\n");
+ else
+ printf("<undefined (%d)>\n", is_ECNenabled);
+#elif USE_WEB100
if (is_ECNenabled == 0)
printf("OFF\n");
else
printf("ON\n");
+#endif
}
/**
* Print details of whether time stamping is on - RFC 1323 related.
- *
+ * web100 1 on, 0 off
+ * web10g 1 on, 2 selfDisabled, 3 peerDisabled
* @param is_timestampenabled
*/
void print_timestamping_RFC1323(int is_timestampenabled) {
printf("RFC 1323 Time Stamping: ");
+#if USE_TCPE
+ if (is_timestampenabled == 1)
+ printf("ON\n");
+ else if (is_timestampenabled == 2)
+ printf("OFF (self)\n");
+ else if (is_timestampenabled == 3)
+ printf("OFF (peer)\n");
+ else
+ printf("<undefined (%d)>\n", is_timestampenabled);
+#elif USE_WEB100
if (is_timestampenabled == 0)
printf("OFF\n");
else
printf("ON\n");
+#endif
}
/**
- [ndt-dev] [ndt] r807 committed - Apply Richard/Dominic's web10g patch, ndt, 04/09/2013
Archive powered by MHonArc 2.6.16.