diff options
author | Peter Kokot <peterkokot@gmail.com> | 2018-10-14 12:56:38 +0200 |
---|---|---|
committer | Peter Kokot <peterkokot@gmail.com> | 2018-10-14 12:56:38 +0200 |
commit | 1ad08256f349fa513157437abc4feb245cce03fc (patch) | |
tree | a6bd8d17fa64b625757ac04b1436696c3e760f61 /sapi/litespeed | |
parent | f87f7bb8c7be413afd02548435112fa2c5030a4a (diff) | |
download | php-git-1ad08256f349fa513157437abc4feb245cce03fc.tar.gz |
Sync leading and final newlines in source code files
This patch adds missing newlines, trims multiple redundant final
newlines into a single one, and trims redundant leading newlines.
According to POSIX, a line is a sequence of zero or more non-' <newline>'
characters plus a terminating '<newline>' character. [1] Files should
normally have at least one final newline character.
C89 [2] and later standards [3] mention a final newline:
"A source file that is not empty shall end in a new-line character,
which shall not be immediately preceded by a backslash character."
Although it is not mandatory for all files to have a final newline
fixed, a more consistent and homogeneous approach brings less of commit
differences issues and a better development experience in certain text
editors and IDEs.
[1] http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_206
[2] https://port70.net/~nsz/c/c89/c89-draft.html#2.1.1.2
[3] https://port70.net/~nsz/c/c99/n1256.html#5.1.1.2
Diffstat (limited to 'sapi/litespeed')
-rw-r--r-- | sapi/litespeed/README.md | 4 | ||||
-rw-r--r-- | sapi/litespeed/lsapidef.h | 1 | ||||
-rw-r--r-- | sapi/litespeed/lsapilib.c | 2 | ||||
-rw-r--r-- | sapi/litespeed/lsapilib.h | 7 | ||||
-rw-r--r-- | sapi/litespeed/lscriu.h | 2 |
5 files changed, 1 insertions, 15 deletions
diff --git a/sapi/litespeed/README.md b/sapi/litespeed/README.md index e744030de7..3f5b7ad14f 100644 --- a/sapi/litespeed/README.md +++ b/sapi/litespeed/README.md @@ -219,7 +219,3 @@ For support questions, please post to our free support forum, at: https://www.litespeedtech.com/support/forum/ For bug report, please send bug report to bug [at] litespeedtech.com. - - - - diff --git a/sapi/litespeed/lsapidef.h b/sapi/litespeed/lsapidef.h index 4db8ff562d..f6c0cb0231 100644 --- a/sapi/litespeed/lsapidef.h +++ b/sapi/litespeed/lsapidef.h @@ -193,4 +193,3 @@ struct lsapi_resp_header #endif - diff --git a/sapi/litespeed/lsapilib.c b/sapi/litespeed/lsapilib.c index 685892e708..a93cdc345d 100644 --- a/sapi/litespeed/lsapilib.c +++ b/sapi/litespeed/lsapilib.c @@ -3962,5 +3962,3 @@ int LSAPI_Inc_Req_Processed(int cnt) { return __sync_add_and_fetch(s_global_counter, cnt); } - - diff --git a/sapi/litespeed/lsapilib.h b/sapi/litespeed/lsapilib.h index 1fd3f56176..ff27c9cd94 100644 --- a/sapi/litespeed/lsapilib.h +++ b/sapi/litespeed/lsapilib.h @@ -418,10 +418,3 @@ void LSAPI_Log(int flag, const char * fmt, ...) #endif - - - - - - - diff --git a/sapi/litespeed/lscriu.h b/sapi/litespeed/lscriu.h index cc0186ef79..02fc9b880a 100644 --- a/sapi/litespeed/lscriu.h +++ b/sapi/litespeed/lscriu.h @@ -64,4 +64,4 @@ void LSCRIU_inc_req_procssed(void); } #endif -#endif // LSCRIU_
\ No newline at end of file +#endif // LSCRIU_ |