svn commit: r259858 - head/sys/netinet/libalias

Gleb Smirnoff glebius at FreeBSD.org
Wed Dec 25 02:06:59 UTC 2013


Author: glebius
Date: Wed Dec 25 02:06:57 2013
New Revision: 259858
URL: http://svnweb.freebsd.org/changeset/base/259858

Log:
  Kill space at eols.

Modified:
  head/sys/netinet/libalias/alias_cuseeme.c
  head/sys/netinet/libalias/alias_dummy.c
  head/sys/netinet/libalias/alias_irc.c
  head/sys/netinet/libalias/alias_nbt.c
  head/sys/netinet/libalias/alias_pptp.c
  head/sys/netinet/libalias/alias_skinny.c
  head/sys/netinet/libalias/alias_smedia.c

Modified: head/sys/netinet/libalias/alias_cuseeme.c
==============================================================================
--- head/sys/netinet/libalias/alias_cuseeme.c	Wed Dec 25 01:58:19 2013	(r259857)
+++ head/sys/netinet/libalias/alias_cuseeme.c	Wed Dec 25 02:06:57 2013	(r259858)
@@ -56,14 +56,14 @@ __FBSDID("$FreeBSD$");
 #define CUSEEME_PORT_NUMBER 7648
 
 static void
-AliasHandleCUSeeMeOut(struct libalias *la, struct ip *pip, 
+AliasHandleCUSeeMeOut(struct libalias *la, struct ip *pip,
 		      struct alias_link *lnk);
 
 static void
-AliasHandleCUSeeMeIn(struct libalias *la, struct ip *pip, 
+AliasHandleCUSeeMeIn(struct libalias *la, struct ip *pip,
 		     struct in_addr original_addr);
 
-static int 
+static int
 fingerprint(struct libalias *la, struct alias_data *ah)
 {
 
@@ -74,7 +74,7 @@ fingerprint(struct libalias *la, struct 
 	return (-1);
 }
 
-static int 
+static int
 protohandlerin(struct libalias *la, struct ip *pip, struct alias_data *ah)
 {
 	
@@ -82,7 +82,7 @@ protohandlerin(struct libalias *la, stru
 	return (0);
 }
 
-static int 
+static int
 protohandlerout(struct libalias *la, struct ip *pip, struct alias_data *ah)
 {
 	
@@ -92,20 +92,20 @@ protohandlerout(struct libalias *la, str
 
 /* Kernel module definition. */
 struct proto_handler handlers[] = {
-	{ 
-	  .pri = 120, 
-	  .dir = OUT, 
-	  .proto = UDP, 
-	  .fingerprint = &fingerprint, 
+	{
+	  .pri = 120,
+	  .dir = OUT,
+	  .proto = UDP,
+	  .fingerprint = &fingerprint,
 	  .protohandler = &protohandlerout
-	}, 
+	},
 	{
-	  .pri = 120, 
-	  .dir = IN, 
-	  .proto = UDP, 
-	  .fingerprint = &fingerprint, 
+	  .pri = 120,
+	  .dir = IN,
+	  .proto = UDP,
+	  .fingerprint = &fingerprint,
 	  .protohandler = &protohandlerin
-	}, 
+	},
 	{ EOH }
 };
 
@@ -130,9 +130,9 @@ mod_handler(module_t mod, int type, void
 }
 
 #ifdef _KERNEL
-static 
+static
 #endif
-moduledata_t 
+moduledata_t
 alias_mod = {
        "alias_cuseeme", mod_handler, NULL
 };

Modified: head/sys/netinet/libalias/alias_dummy.c
==============================================================================
--- head/sys/netinet/libalias/alias_dummy.c	Wed Dec 25 01:58:19 2013	(r259857)
+++ head/sys/netinet/libalias/alias_dummy.c	Wed Dec 25 02:06:57 2013	(r259858)
@@ -27,7 +27,7 @@
 #include <sys/cdefs.h>
 __FBSDID("$FreeBSD$");
 
-/* 
+/*
  * Alias_dummy is just an empty skeleton used to demostrate how to write
  * a module for libalias, that will run unalterated in userland or in
  * kernel land.
@@ -59,19 +59,19 @@ __FBSDID("$FreeBSD$");
 static void
 AliasHandleDummy(struct libalias *la, struct ip *ip, struct alias_data *ah);
 
-static int 
+static int
 fingerprint(struct libalias *la, struct alias_data *ah)
 {
 
-	/* 
-	 * Check here all the data that will be used later, if any field 
+	/*
+	 * Check here all the data that will be used later, if any field
 	 * is empy/NULL, return a -1 value.
 	 */
-	if (ah->dport == NULL || ah->sport == NULL || ah->lnk == NULL || 
+	if (ah->dport == NULL || ah->sport == NULL || ah->lnk == NULL ||
 		ah->maxpktsize == 0)
 		return (-1);
-	/* 
-	 * Fingerprint the incoming packet, if it matches any conditions 
+	/*
+	 * Fingerprint the incoming packet, if it matches any conditions
 	 * return an OK value.
 	 */
 	if (ntohs(*ah->dport) == 123
@@ -80,12 +80,12 @@ fingerprint(struct libalias *la, struct 
 	return (-1); /* I don't recognize this packet. */
 }
 
-/* 
- * Wrap in this general purpose function, the real function used to alias the 
+/*
+ * Wrap in this general purpose function, the real function used to alias the
  * packets.
  */
 
-static int 
+static int
 protohandler(struct libalias *la, struct ip *pip, struct alias_data *ah)
 {
 	
@@ -93,22 +93,22 @@ protohandler(struct libalias *la, struct
 	return (0);
 }
 
-/* 
- * NOTA BENE: the next variable MUST NOT be renamed in any case if you want 
- * your module to work in userland, cause it's used to find and use all 
+/*
+ * NOTA BENE: the next variable MUST NOT be renamed in any case if you want
+ * your module to work in userland, cause it's used to find and use all
  * the protocol handlers present in every module.
- * So WATCH OUT, your module needs this variables and it needs it with 
+ * So WATCH OUT, your module needs this variables and it needs it with
  * ITS EXACT NAME: handlers.
  */
 
 struct proto_handler handlers [] = {
-	{ 
-	  .pri = 666, 
-	  .dir = IN|OUT, 
-	  .proto = UDP|TCP, 
-	  .fingerprint = &fingerprint, 
+	{
+	  .pri = 666,
+	  .dir = IN|OUT,
+	  .proto = UDP|TCP,
+	  .fingerprint = &fingerprint,
 	  .protohandler = &protohandler
-	}, 
+	},
 	{ EOH }
 };
 
@@ -117,7 +117,7 @@ mod_handler(module_t mod, int type, void
 {
 	int error;
 
-	switch (type) {	  
+	switch (type) {	
 	case MOD_LOAD:
 		error = 0;
 		LibAliasAttachHandlers(handlers);

Modified: head/sys/netinet/libalias/alias_irc.c
==============================================================================
--- head/sys/netinet/libalias/alias_irc.c	Wed Dec 25 01:58:19 2013	(r259857)
+++ head/sys/netinet/libalias/alias_irc.c	Wed Dec 25 02:06:57 2013	(r259858)
@@ -92,11 +92,11 @@ static void
 AliasHandleIrcOut(struct libalias *, struct ip *, struct alias_link *,	
 		  int maxpacketsize);
 
-static int 
+static int
 fingerprint(struct libalias *la, struct alias_data *ah)
 {
 
-	if (ah->dport == NULL || ah->dport == NULL || ah->lnk == NULL || 
+	if (ah->dport == NULL || ah->dport == NULL || ah->lnk == NULL ||
 	    ah->maxpktsize == 0)
 		return (-1);
 	if (ntohs(*ah->dport) == IRC_CONTROL_PORT_NUMBER_1
@@ -105,7 +105,7 @@ fingerprint(struct libalias *la, struct 
 	return (-1);
 }
 
-static int 
+static int
 protohandler(struct libalias *la, struct ip *pip, struct alias_data *ah)
 {
 
@@ -118,13 +118,13 @@ protohandler(struct libalias *la, struct
 }
 
 struct proto_handler handlers[] = {
-	{ 
-	  .pri = 90, 
-	  .dir = OUT, 
-	  .proto = TCP, 
-	  .fingerprint = &fingerprint, 
+	{
+	  .pri = 90,
+	  .dir = OUT,
+	  .proto = TCP,
+	  .fingerprint = &fingerprint,
 	  .protohandler = &protohandler
-	}, 
+	},
 	{ EOH }
 };
 
@@ -149,7 +149,7 @@ mod_handler(module_t mod, int type, void
 }
 
 #ifdef _KERNEL
-static 
+static
 #endif
 moduledata_t alias_mod = {
        "alias_irc", mod_handler, NULL

Modified: head/sys/netinet/libalias/alias_nbt.c
==============================================================================
--- head/sys/netinet/libalias/alias_nbt.c	Wed Dec 25 01:58:19 2013	(r259857)
+++ head/sys/netinet/libalias/alias_nbt.c	Wed Dec 25 02:06:57 2013	(r259858)
@@ -70,17 +70,17 @@ __FBSDID("$FreeBSD$");
 #define NETBIOS_DGM_PORT_NUMBER 138
 
 static int
-AliasHandleUdpNbt(struct libalias *, struct ip *, struct alias_link *, 
+AliasHandleUdpNbt(struct libalias *, struct ip *, struct alias_link *,
 		  struct in_addr *, u_short);
 
 static int
 AliasHandleUdpNbtNS(struct libalias *, struct ip *, struct alias_link *,
 		    struct in_addr *, u_short *, struct in_addr *, u_short *);
-static int 
+static int
 fingerprint1(struct libalias *la, struct alias_data *ah)
 {
 
-	if (ah->dport == NULL || ah->sport == NULL || ah->lnk == NULL || 
+	if (ah->dport == NULL || ah->sport == NULL || ah->lnk == NULL ||
 	    ah->aaddr == NULL || ah->aport == NULL)
 		return (-1);
 	if (ntohs(*ah->dport) == NETBIOS_DGM_PORT_NUMBER
@@ -89,18 +89,18 @@ fingerprint1(struct libalias *la, struct
 	return (-1);
 }
 
-static int 
+static int
 protohandler1(struct libalias *la, struct ip *pip, struct alias_data *ah)
 {
 	
 	return (AliasHandleUdpNbt(la, pip, ah->lnk, ah->aaddr, *ah->aport));
 }
 
-static int 
+static int
 fingerprint2(struct libalias *la, struct alias_data *ah)
 {
 
-	if (ah->dport == NULL || ah->sport == NULL || ah->lnk == NULL || 
+	if (ah->dport == NULL || ah->sport == NULL || ah->lnk == NULL ||
 	    ah->aaddr == NULL || ah->aport == NULL)
 		return (-1);
 	if (ntohs(*ah->dport) == NETBIOS_NS_PORT_NUMBER
@@ -109,7 +109,7 @@ fingerprint2(struct libalias *la, struct
 	return (-1);
 }
 
-static int 
+static int
 protohandler2in(struct libalias *la, struct ip *pip, struct alias_data *ah)
 {
 	
@@ -118,7 +118,7 @@ protohandler2in(struct libalias *la, str
 	return (0);
 }
 
-static int 
+static int
 protohandler2out(struct libalias *la, struct ip *pip, struct alias_data *ah)
 {
 	
@@ -128,27 +128,27 @@ protohandler2out(struct libalias *la, st
 
 /* Kernel module definition. */
 struct proto_handler handlers[] = {
-	{ 
-	  .pri = 130, 
-	  .dir = IN|OUT, 
-	  .proto = UDP, 
-	  .fingerprint = &fingerprint1, 
+	{
+	  .pri = 130,
+	  .dir = IN|OUT,
+	  .proto = UDP,
+	  .fingerprint = &fingerprint1,
 	  .protohandler = &protohandler1
-	}, 
-	{ 
-	  .pri = 140, 
-	  .dir = IN, 
-	  .proto = UDP, 
-	  .fingerprint = &fingerprint2, 
+	},
+	{
+	  .pri = 140,
+	  .dir = IN,
+	  .proto = UDP,
+	  .fingerprint = &fingerprint2,
 	  .protohandler = &protohandler2in
-	}, 
-	{ 
-	  .pri = 140, 
-	  .dir = OUT, 
-	  .proto = UDP, 
-	  .fingerprint = &fingerprint2, 
+	},
+	{
+	  .pri = 140,
+	  .dir = OUT,
+	  .proto = UDP,
+	  .fingerprint = &fingerprint2,
 	  .protohandler = &protohandler2out
-	}, 
+	},
 	{ EOH }
 };
 
@@ -173,7 +173,7 @@ mod_handler(module_t mod, int type, void
 }
 
 #ifdef	_KERNEL
-static 
+static
 #endif
 moduledata_t alias_mod = {
        "alias_nbt", mod_handler, NULL

Modified: head/sys/netinet/libalias/alias_pptp.c
==============================================================================
--- head/sys/netinet/libalias/alias_pptp.c	Wed Dec 25 01:58:19 2013	(r259857)
+++ head/sys/netinet/libalias/alias_pptp.c	Wed Dec 25 02:06:57 2013	(r259858)
@@ -78,7 +78,7 @@ AliasHandlePptpGreOut(struct libalias *,
 static int
 AliasHandlePptpGreIn(struct libalias *, struct ip *);
 
-static int 
+static int
 fingerprint(struct libalias *la, struct alias_data *ah)
 {
 
@@ -90,14 +90,14 @@ fingerprint(struct libalias *la, struct 
 	return (-1);
 }
 
-static int 
+static int
 fingerprintgre(struct libalias *la, struct alias_data *ah)
 {
 
 	return (0);
 }
 
-static int 
+static int
 protohandlerin(struct libalias *la, struct ip *pip, struct alias_data *ah)
 {
 	
@@ -105,7 +105,7 @@ protohandlerin(struct libalias *la, stru
 	return (0);
 }
 
-static int 
+static int
 protohandlerout(struct libalias *la, struct ip *pip, struct alias_data *ah)
 {
 	
@@ -113,7 +113,7 @@ protohandlerout(struct libalias *la, str
 	return (0);
 }
 
-static int 
+static int
 protohandlergrein(struct libalias *la, struct ip *pip, struct alias_data *ah)
 {
 
@@ -123,7 +123,7 @@ protohandlergrein(struct libalias *la, s
 	return (-1);
 }
 
-static int 
+static int
 protohandlergreout(struct libalias *la, struct ip *pip, struct alias_data *ah)
 {
 
@@ -134,39 +134,39 @@ protohandlergreout(struct libalias *la, 
 
 /* Kernel module definition. */
 struct proto_handler handlers[] = {
-	{ 
-	  .pri = 200, 
-	  .dir = IN, 
-	  .proto = TCP, 
-	  .fingerprint = &fingerprint, 
+	{
+	  .pri = 200,
+	  .dir = IN,
+	  .proto = TCP,
+	  .fingerprint = &fingerprint,
 	  .protohandler = &protohandlerin
 	},
-	{ 
-	  .pri = 210, 
-	  .dir = OUT, 
-	  .proto = TCP, 
-	  .fingerprint = &fingerprint, 
+	{
+	  .pri = 210,
+	  .dir = OUT,
+	  .proto = TCP,
+	  .fingerprint = &fingerprint,
 	  .protohandler = &protohandlerout
 	},
-/* 
- * WATCH OUT!!! these 2 handlers NEED a priority of INT_MAX (highest possible) 
+/*
+ * WATCH OUT!!! these 2 handlers NEED a priority of INT_MAX (highest possible)
  * cause they will ALWAYS process packets, so they must be the last one
  * in chain: look fingerprintgre() above.
  */
-	{ 
-	  .pri = INT_MAX, 
-	  .dir = IN, 
-	  .proto = IP, 
-	  .fingerprint = &fingerprintgre, 
+	{
+	  .pri = INT_MAX,
+	  .dir = IN,
+	  .proto = IP,
+	  .fingerprint = &fingerprintgre,
 	  .protohandler = &protohandlergrein
 	},
-	{ 
-	  .pri = INT_MAX, 
-	  .dir = OUT, 
-	  .proto = IP, 
-	  .fingerprint = &fingerprintgre, 
+	{
+	  .pri = INT_MAX,
+	  .dir = OUT,
+	  .proto = IP,
+	  .fingerprint = &fingerprintgre,
 	  .protohandler = &protohandlergreout
-	}, 
+	},
 	{ EOH }
 };
 static int
@@ -190,7 +190,7 @@ mod_handler(module_t mod, int type, void
 }
 
 #ifdef _KERNEL
-static 
+static
 #endif
 moduledata_t alias_mod = {
        "alias_pptp", mod_handler, NULL

Modified: head/sys/netinet/libalias/alias_skinny.c
==============================================================================
--- head/sys/netinet/libalias/alias_skinny.c	Wed Dec 25 01:58:19 2013	(r259857)
+++ head/sys/netinet/libalias/alias_skinny.c	Wed Dec 25 02:06:57 2013	(r259858)
@@ -56,7 +56,7 @@
 static void
 AliasHandleSkinny(struct libalias *, struct ip *, struct alias_link *);
 
-static int 
+static int
 fingerprint(struct libalias *la, struct alias_data *ah)
 {
 
@@ -68,7 +68,7 @@ fingerprint(struct libalias *la, struct 
 	return (-1);
 }
 
-static int 
+static int
 protohandler(struct libalias *la, struct ip *pip, struct alias_data *ah)
 {
 	
@@ -77,13 +77,13 @@ protohandler(struct libalias *la, struct
 }
 
 struct proto_handler handlers[] = {
-	{ 
-	  .pri = 110, 
-	  .dir = IN|OUT, 
-	  .proto = TCP, 
-	  .fingerprint = &fingerprint, 
+	{
+	  .pri = 110,
+	  .dir = IN|OUT,
+	  .proto = TCP,
+	  .fingerprint = &fingerprint,
 	  .protohandler = &protohandler
-	}, 
+	},
 	{ EOH }
 };
 
@@ -108,7 +108,7 @@ mod_handler(module_t mod, int type, void
 }
 
 #ifdef _KERNEL
-static 
+static
 #endif
 moduledata_t alias_mod = {
        "alias_skinny", mod_handler, NULL

Modified: head/sys/netinet/libalias/alias_smedia.c
==============================================================================
--- head/sys/netinet/libalias/alias_smedia.c	Wed Dec 25 01:58:19 2013	(r259857)
+++ head/sys/netinet/libalias/alias_smedia.c	Wed Dec 25 02:06:57 2013	(r259858)
@@ -131,14 +131,14 @@ __FBSDID("$FreeBSD$");
 static void
 AliasHandleRtspOut(struct libalias *, struct ip *, struct alias_link *,	
 		  int maxpacketsize);
-static int 
+static int
 fingerprint(struct libalias *la, struct alias_data *ah)
 {
 
 	if (ah->dport != NULL && ah->aport != NULL && ah->sport != NULL &&
             ntohs(*ah->dport) == TFTP_PORT_NUMBER)
 		return (0);
-	if (ah->dport == NULL || ah->sport == NULL || ah->lnk == NULL || 
+	if (ah->dport == NULL || ah->sport == NULL || ah->lnk == NULL ||
 	    ah->maxpktsize == 0)
 		return (-1);
 	if (ntohs(*ah->dport) == RTSP_CONTROL_PORT_NUMBER_1
@@ -149,7 +149,7 @@ fingerprint(struct libalias *la, struct 
 	return (-1);
 }
 
-static int 
+static int
 protohandler(struct libalias *la, struct ip *pip, struct alias_data *ah)
 {
 	
@@ -161,13 +161,13 @@ protohandler(struct libalias *la, struct
 }
 
 struct proto_handler handlers[] = {
-	{ 
-	  .pri = 100, 
-	  .dir = OUT, 
+	{
+	  .pri = 100,
+	  .dir = OUT,
 	  .proto = TCP|UDP,
-	  .fingerprint = &fingerprint, 
+	  .fingerprint = &fingerprint,
 	  .protohandler = &protohandler
-	}, 
+	},
 	{ EOH }
 };
 
@@ -192,7 +192,7 @@ mod_handler(module_t mod, int type, void
 }
 
 #ifdef _KERNEL
-static 
+static
 #endif
 moduledata_t alias_mod = {
        "alias_smedia", mod_handler, NULL
@@ -406,7 +406,7 @@ alias_rtsp_out(struct libalias *la, stru
 	SetAckModified(lnk);
 	tc = (struct tcphdr *)ip_next(pip);
 	delta = GetDeltaSeqOut(tc->th_seq, lnk);
-	AddSeq(lnk, delta + new_dlen - dlen, pip->ip_hl, pip->ip_len, 
+	AddSeq(lnk, delta + new_dlen - dlen, pip->ip_hl, pip->ip_len,
 	    tc->th_seq, tc->th_off);
 
 	new_len = htons(hlen + new_dlen);


More information about the svn-src-all mailing list