projects
/
curl
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f7bb1fc
)
CODE_STYLE: indend example code
author
Daniel Stenberg
<daniel@haxx.se>
Tue, 22 Mar 2016 07:19:08 +0000
(08:19 +0100)
committer
Daniel Stenberg
<daniel@haxx.se>
Tue, 22 Mar 2016 07:36:21 +0000
(08:36 +0100)
... to make it look nicer in markdown outputa
docs/CODE_STYLE.md
patch
|
blob
|
history
diff --git
a/docs/CODE_STYLE.md
b/docs/CODE_STYLE.md
index d77fc44764b4642a170f3da43360e3d061071933..033a33bce70962f170d5b27d081ef3441c310f93 100644
(file)
--- a/
docs/CODE_STYLE.md
+++ b/
docs/CODE_STYLE.md
@@
-107,13
+107,11
@@
Rather than test a conditional value such as a bool against TRUE or FALSE, a
pointer against NULL or != NULL and an int against zero or not zero in
if/while conditions we prefer:
-CURLcode result = CURLE_OK;
-
-result = do_something();
-if(!result) {
- /* something went wrong */
- return result;
-}
+ result = do_something();
+ if(!result) {
+ /* something went wrong */
+ return result;
+ }
## No assignments in conditions