[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] [gnurl] 188/256: checksrc: detect and warn for multiple spa
From: |
gnunet |
Subject: |
[GNUnet-SVN] [gnurl] 188/256: checksrc: detect and warn for multiple spaces |
Date: |
Fri, 06 Oct 2017 19:44:39 +0200 |
This is an automated email from the git hooks/post-receive script.
ng0 pushed a commit to branch master
in repository gnurl.
commit 59813726d1638880494e3675ae8230b6bdd21ee5
Author: Daniel Stenberg <address@hidden>
AuthorDate: Tue Sep 12 09:28:37 2017 +0200
checksrc: detect and warn for multiple spaces
---
lib/checksrc.pl | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/lib/checksrc.pl b/lib/checksrc.pl
index 535e3d9f5..c1f74bebf 100755
--- a/lib/checksrc.pl
+++ b/lib/checksrc.pl
@@ -62,6 +62,7 @@ my %warnings = (
'EQUALSNOSPACE' => 'equals sign without following space',
'NOSPACEEQUALS' => 'equals sign without preceeding space',
'SEMINOSPACE' => 'semicolon without following space',
+ 'MULTISPACE' => 'multiple spaces used when not suitable',
);
sub readwhitelist {
@@ -563,6 +564,18 @@ sub scanfile {
"no space after semilcolon");
}
+ # check for more than one consecutive space before open brace or
+ # question mark. Skip lines containing strings since they make it hard
+ # due to artificially getting multiple spaces
+ if(($l eq $nostr) &&
+ $nostr =~ /^(.*(\S)) + [{?]/i) {
+ checkwarn("MULTISPACE",
+ $line, length($1)+1, $file, $ol,
+ "multiple space");
+ print STDERR "L: $l\n";
+ print STDERR "nostr: $nostr\n";
+ }
+
$line++;
$prevl = $ol;
}
--
To stop receiving notification emails like this one, please contact
address@hidden
- [GNUnet-SVN] [gnurl] 157/256: mime: implement encoders., (continued)
- [GNUnet-SVN] [gnurl] 157/256: mime: implement encoders., gnunet, 2017/10/06
- [GNUnet-SVN] [gnurl] 133/256: mime: fix signed/unsigned conversions., gnunet, 2017/10/06
- [GNUnet-SVN] [gnurl] 140/256: examples/post-callback: stop returning one byte at a time, gnunet, 2017/10/06
- [GNUnet-SVN] [gnurl] 143/256: mime: use CURL_ZERO_TERMINATED in examples, gnunet, 2017/10/06
- [GNUnet-SVN] [gnurl] 46/256: request-target.d: mention added in 7.55.0, gnunet, 2017/10/06
- [GNUnet-SVN] [gnurl] 56/256: winbuild: fix embedded manifest option, gnunet, 2017/10/06
- [GNUnet-SVN] [gnurl] 236/256: connect: fix race condition with happy eyeballs timeout, gnunet, 2017/10/06
- [GNUnet-SVN] [gnurl] 44/256: makefile.m32: add support for libidn2, gnunet, 2017/10/06
- [GNUnet-SVN] [gnurl] 167/256: vtls: switch to CURL_SHA256_DIGEST_LENGTH define, gnunet, 2017/10/06
- [GNUnet-SVN] [gnurl] 54/256: examples/threaded-ssl: mention that this is for openssl before 1.1, gnunet, 2017/10/06
- [GNUnet-SVN] [gnurl] 188/256: checksrc: detect and warn for multiple spaces,
gnunet <=
- [GNUnet-SVN] [gnurl] 233/256: http: add custom empty headers to repeated requests, gnunet, 2017/10/06
- [GNUnet-SVN] [gnurl] 115/256: ossfuzz: moving towards the ideal integration, gnunet, 2017/10/06
- [GNUnet-SVN] [gnurl] 241/256: cookie: fix memory leak if path was set twice in header, gnunet, 2017/10/06
- [GNUnet-SVN] [gnurl] 49/256: test1453: Fixed <features>, gnunet, 2017/10/06
- [GNUnet-SVN] [gnurl] 204/256: curl: make str2udouble not return values on error, gnunet, 2017/10/06
- [GNUnet-SVN] [gnurl] 225/256: symbols-in-versions: fix CURLSSLSET_NO_BACKENDS entry, gnunet, 2017/10/06
- [GNUnet-SVN] [gnurl] 196/256: docs: clarify the CURLOPT_INTERLEAVE* options behavior, gnunet, 2017/10/06
- [GNUnet-SVN] [gnurl] 154/256: mime: unified to use the typedef'd mime structs everywhere, gnunet, 2017/10/06
- [GNUnet-SVN] [gnurl] 246/256: FTP: zero terminate the entry path even on bad input, gnunet, 2017/10/06
- [GNUnet-SVN] [gnurl] 102/256: RELEASE-NOTES: synced with 8c33c963a, gnunet, 2017/10/06