lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20210608071117.12634-5-thunder.leizhen@huawei.com>
Date:   Tue, 8 Jun 2021 15:11:16 +0800
From:   Zhen Lei <thunder.leizhen@...wei.com>
To:     Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        Andrew Morton <akpm@...ux-foundation.org>,
        linux-kernel <linux-kernel@...r.kernel.org>
CC:     Zhen Lei <thunder.leizhen@...wei.com>
Subject: [PATCH 4/5] lib/ts_bm.c: remove trailing spaces and tabs

Run the following command to find and remove the trailing spaces and tabs:

sed -r -i 's/[ \t]+$//' lib/ts_bm.c

Signed-off-by: Zhen Lei <thunder.leizhen@...wei.com>
---
 lib/ts_bm.c | 24 ++++++++++++------------
 1 file changed, 12 insertions(+), 12 deletions(-)

diff --git a/lib/ts_bm.c b/lib/ts_bm.c
index 4cf250031f0f..65e6489597a2 100644
--- a/lib/ts_bm.c
+++ b/lib/ts_bm.c
@@ -5,27 +5,27 @@
  * Authors:	Pablo Neira Ayuso <pablo@...odev.net>
  *
  * ==========================================================================
- * 
+ *
  *   Implements Boyer-Moore string matching algorithm:
  *
  *   [1] A Fast String Searching Algorithm, R.S. Boyer and Moore.
- *       Communications of the Association for Computing Machinery, 
+ *       Communications of the Association for Computing Machinery,
  *       20(10), 1977, pp. 762-772.
  *       https://www.cs.utexas.edu/users/moore/publications/fstrpos.pdf
  *
  *   [2] Handbook of Exact String Matching Algorithms, Thierry Lecroq, 2004
  *       http://www-igm.univ-mlv.fr/~lecroq/string/string.pdf
  *
- *   Note: Since Boyer-Moore (BM) performs searches for matchings from right 
- *   to left, it's still possible that a matching could be spread over 
+ *   Note: Since Boyer-Moore (BM) performs searches for matchings from right
+ *   to left, it's still possible that a matching could be spread over
  *   multiple blocks, in that case this algorithm won't find any coincidence.
- *   
+ *
  *   If you're willing to ensure that such thing won't ever happen, use the
- *   Knuth-Pratt-Morris (KMP) implementation instead. In conclusion, choose 
- *   the proper string search algorithm depending on your setting. 
+ *   Knuth-Pratt-Morris (KMP) implementation instead. In conclusion, choose
+ *   the proper string search algorithm depending on your setting.
  *
- *   Say you're using the textsearch infrastructure for filtering, NIDS or 
- *   any similar security focused purpose, then go KMP. Otherwise, if you 
+ *   Say you're using the textsearch infrastructure for filtering, NIDS or
+ *   any similar security focused purpose, then go KMP. Otherwise, if you
  *   really care about performance, say you're classifying packets to apply
  *   Quality of Service (QoS) policies, and you don't mind about possible
  *   matchings spread over multiple fragments, then go BM.
@@ -70,9 +70,9 @@ static unsigned int bm_find(struct ts_config *conf, struct ts_state *state)
 			break;
 
 		while (shift < text_len) {
-			DEBUGP("Searching in position %d (%c)\n", 
+			DEBUGP("Searching in position %d (%c)\n",
 				shift, text[shift]);
-			for (i = 0; i < bm->patlen; i++) 
+			for (i = 0; i < bm->patlen; i++)
 				if ((icase ? toupper(text[shift-i])
 				    : text[shift-i])
 					!= bm->pattern[bm->patlen-1-i])
@@ -124,7 +124,7 @@ static void compute_prefix_tbl(struct ts_bm *bm, int flags)
 			    = bm->patlen - 1 - i;
 	}
 
-	/* Compute the good shift array, used to match reocurrences 
+	/* Compute the good shift array, used to match reocurrences
 	 * of a subpattern */
 	bm->good_shift[0] = 1;
 	for (i = 1; i < bm->patlen; i++)
-- 
2.25.1


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ