Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 4 Jan 2016 07:06:46 +0000 (UTC)
From:      Garrett Cooper <ngie@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject:   svn commit: r293143 - stable/10/tests/sys/kern
Message-ID:  <201601040706.u0476k7j082804@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: ngie
Date: Mon Jan  4 07:06:46 2016
New Revision: 293143
URL: https://svnweb.freebsd.org/changeset/base/293143

Log:
  MFC r292820:
  
  Clean trailing whitespace

Modified:
  stable/10/tests/sys/kern/unix_seqpacket_test.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/tests/sys/kern/unix_seqpacket_test.c
==============================================================================
--- stable/10/tests/sys/kern/unix_seqpacket_test.c	Mon Jan  4 07:04:58 2016	(r293142)
+++ stable/10/tests/sys/kern/unix_seqpacket_test.c	Mon Jan  4 07:06:46 2016	(r293143)
@@ -47,7 +47,7 @@ static void
 do_socketpair(int *sv)
 {
 	int s;
-	
+
 	s = socketpair(PF_LOCAL, SOCK_SEQPACKET, 0, sv);
 	ATF_REQUIRE_EQ(0, s);
 	ATF_REQUIRE(sv[0] >= 0);
@@ -59,7 +59,7 @@ static void
 do_socketpair_nonblocking(int *sv)
 {
 	int s;
-	
+
 	s = socketpair(PF_LOCAL, SOCK_SEQPACKET, 0, sv);
 	ATF_REQUIRE_EQ(0, s);
 	ATF_REQUIRE(sv[0] >= 0);
@@ -69,7 +69,7 @@ do_socketpair_nonblocking(int *sv)
 	ATF_REQUIRE(-1 != fcntl(sv[1], F_SETFL, O_NONBLOCK));
 }
 
-/* 
+/*
  * Returns a pair of sockets made the hard way: bind, listen, connect & accept
  * @return	const char* The path to the socket
  */
@@ -101,7 +101,7 @@ mk_pair_of_sockets(int *sv)
 		perror("connect");
 		atf_tc_fail("connect(2) failed");
 	}
-	
+
 	/* Accept it */
 	s1 = accept(s, NULL, NULL);
 	if (s1 == -1) {
@@ -232,7 +232,7 @@ test_pipe_simulator(size_t sndbufsize, s
 			memset(sndbuf, num_sent, pktsize);
 			ssize = send(sv[0], sndbuf, pktsize, MSG_EOR);
 			if (ssize < 0) {
-				/* 
+				/*
 				 * XXX: This is bug-compatible with the kernel.
 				 * The kernel returns EMSGSIZE when it should
 				 * return EAGAIN
@@ -268,7 +268,7 @@ test_pipe_simulator(size_t sndbufsize, s
 				    pktsize, rsize);
 				memset(comparebuf, num_received, pktsize);
 				ATF_CHECK_EQ_MSG(0, memcmp(comparebuf, rcvbuf,
-				    			   pktsize), 
+				    			   pktsize),
 				    "Received data miscompare");
 				num_received++;
 			}
@@ -324,7 +324,7 @@ test_pipe_reader(void* args)
 		    		 "expected %zd=send(...) but got %zd",
 				 td->pktsize, rsize);
 		d = memcmp(comparebuf, rcvbuf, td->pktsize);
-		ATF_CHECK_EQ_MSG(0, d, 
+		ATF_CHECK_EQ_MSG(0, d,
 		    		 "Received data miscompare on packet %d", i);
 	}
 	return (0);
@@ -360,7 +360,7 @@ test_pipe(size_t sndbufsize, size_t rcvb
 	reader_data.so = sv[1];
 	ATF_REQUIRE_EQ(0, pthread_create(&writer, NULL, test_pipe_writer,
 	    				 (void*)&writer_data));
-	/* 
+	/*
 	 * Give the writer time to start writing, and hopefully block, before
 	 * starting the reader.  This increases the likelihood of the test case
 	 * failing due to PR kern/185812
@@ -539,7 +539,7 @@ ATF_TC_BODY(resize_buffers, tc)
 	ATF_CHECK_EQ(0, getsockopt(s, SOL_SOCKET, SO_SNDBUF, &xs, &sl));
 	ATF_CHECK_EQ(0, getsockopt(s, SOL_SOCKET, SO_RCVBUF, &xr, &sl));
 	printf("After changing SNDBUF         | %7d | %7d |\n", xs, xr);
-	
+
 	if (setsockopt(s, SOL_SOCKET, SO_RCVBUF, &rcvbuf, sizeof(rcvbuf)) != 0){
 		perror("setsockopt");
 		atf_tc_fail("setsockopt(SO_RCVBUF) failed");
@@ -676,7 +676,7 @@ ATF_TC_BODY(sendto_recvfrom, tc)
 	}
 	ATF_CHECK_EQ(datalen, rsize);
 
-	/* 
+	/*
 	 * FreeBSD does not currently provide the source address for SEQ_PACKET
 	 * AF_UNIX sockets, and POSIX does not require it, so these two checks
 	 * are disabled.  If FreeBSD gains that feature in the future, then
@@ -686,7 +686,7 @@ ATF_TC_BODY(sendto_recvfrom, tc)
 	/* ATF_CHECK_STREQ(path, ((struct sockaddr_un*)&from)->sun_path); */
 }
 
-/* 
+/*
  * send(2) and recv(2) a single short record with sockets created the
  * traditional way, involving bind, listen, connect, and accept
  */
@@ -782,7 +782,7 @@ ATF_TC_BODY(send_recv_nonblocking, tc)
 	ATF_CHECK_EQ(datalen, rsize);
 }
 
-/* 
+/*
  * We should get EMSGSIZE if we try to send a message larger than the socket
  * buffer, with blocking sockets
  */
@@ -809,7 +809,7 @@ ATF_TC_BODY(emsgsize, tc)
 	ATF_CHECK_EQ(-1, ssize);
 }
 
-/* 
+/*
  * We should get EMSGSIZE if we try to send a message larger than the socket
  * buffer, with nonblocking sockets
  */
@@ -837,7 +837,7 @@ ATF_TC_BODY(emsgsize_nonblocking, tc)
 }
 
 
-/* 
+/*
  * We should get EAGAIN if we try to send a message larger than the socket
  * buffer, with nonblocking sockets.  Test with several different sockbuf sizes
  */
@@ -863,7 +863,7 @@ ATF_TC_BODY(eagain_128k_128k, tc)
 }
 
 
-/* 
+/*
  * nonblocking send(2) and recv(2) of several records, which should collectively
  * fill up the send buffer but not the receive buffer
  */
@@ -888,7 +888,7 @@ ATF_TC_BODY(rcvbuf_oversized, tc)
 	ATF_REQUIRE_EQ(0, setsockopt(sv[1], SOL_SOCKET, SO_RCVBUF, &rcvbufsize,
 	    sizeof(rcvbufsize)));
 
-	/* 
+	/*
 	 * Send and receive packets that are collectively greater than the send
 	 * buffer, but less than the receive buffer
 	 */
@@ -916,7 +916,7 @@ ATF_TC_BODY(rcvbuf_oversized, tc)
 		    "expected %zd=send(...) but got %zd", pktsize, rsize);
 
 		/* Verify the contents */
-		ATF_CHECK_EQ_MSG(0, memcmp(sndbuf, recv_buf, pktsize), 
+		ATF_CHECK_EQ_MSG(0, memcmp(sndbuf, recv_buf, pktsize),
 		    "Received data miscompare");
 	}
 
@@ -926,7 +926,7 @@ ATF_TC_BODY(rcvbuf_oversized, tc)
 	ATF_CHECK_EQ(-1, rsize);
 }
 
-/* 
+/*
  * Simulate the behavior of a blocking pipe.  The sender will send until his
  * buffer fills up, then we'll simulate a scheduler switch that will allow the
  * receiver to read until his buffer empties.  Repeat the process until the
@@ -957,7 +957,7 @@ ATF_TC_BODY(pipe_simulator_128k_128k, tc
 	test_pipe_simulator(131072, 131072);
 }
 
-/* 
+/*
  * Test blocking I/O by passing data between two threads.  The total amount of
  * data will be >> buffer size to force blocking.  Repeat the test with multiple
  * send and receive buffer sizes



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201601040706.u0476k7j082804>