summaryrefslogtreecommitdiff
path: root/src/basic/extract-word.c
diff options
context:
space:
mode:
authorVito Caputo <vito.caputo@coreos.com>2016-02-22 20:32:04 -0800
committerSven Eden <yamakuzure@gmx.net>2017-06-16 10:12:57 +0200
commitbc983c987eb3f92eceb373ba4e1c2076b0b3ca88 (patch)
treeea6f34eed7297fc3cd0a7bd64835bd310603fb7b /src/basic/extract-word.c
parent3c84247622c7d6ad51e7a49907995e3e48b5f472 (diff)
tree-wide: make ++/-- usage consistent WRT spacing
Throughout the tree there's spurious use of spaces separating ++ and -- operators from their respective operands. Make ++ and -- operator consistent with the majority of existing uses; discard the spaces.
Diffstat (limited to 'src/basic/extract-word.c')
-rw-r--r--src/basic/extract-word.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/basic/extract-word.c b/src/basic/extract-word.c
index 97a02220c..bace3c183 100644
--- a/src/basic/extract-word.c
+++ b/src/basic/extract-word.c
@@ -63,12 +63,12 @@ int extract_first_word(const char **p, char **ret, const char *separators, Extra
if (!GREEDY_REALLOC(s, allocated, sz+1))
return -ENOMEM;
- for (;; (*p) ++, c = **p) {
+ for (;; (*p)++, c = **p) {
if (c == 0)
goto finish_force_terminate;
else if (strchr(separators, c)) {
if (flags & EXTRACT_DONT_COALESCE_SEPARATORS) {
- (*p) ++;
+ (*p)++;
goto finish_force_next;
}
} else {
@@ -81,7 +81,7 @@ int extract_first_word(const char **p, char **ret, const char *separators, Extra
}
}
- for (;; (*p) ++, c = **p) {
+ for (;; (*p)++, c = **p) {
if (backslash) {
if (!GREEDY_REALLOC(s, allocated, sz+7))
return -ENOMEM;
@@ -129,7 +129,7 @@ int extract_first_word(const char **p, char **ret, const char *separators, Extra
backslash = false;
} else if (quote) { /* inside either single or double quotes */
- for (;; (*p) ++, c = **p) {
+ for (;; (*p)++, c = **p) {
if (c == 0) {
if (flags & EXTRACT_RELAX)
goto finish_force_terminate;
@@ -149,7 +149,7 @@ int extract_first_word(const char **p, char **ret, const char *separators, Extra
}
} else {
- for (;; (*p) ++, c = **p) {
+ for (;; (*p)++, c = **p) {
if (c == 0)
goto finish_force_terminate;
else if ((c == '\'' || c == '"') && (flags & EXTRACT_QUOTES)) {
@@ -160,11 +160,11 @@ int extract_first_word(const char **p, char **ret, const char *separators, Extra
break;
} else if (strchr(separators, c)) {
if (flags & EXTRACT_DONT_COALESCE_SEPARATORS) {
- (*p) ++;
+ (*p)++;
goto finish_force_next;
}
/* Skip additional coalesced separators. */
- for (;; (*p) ++, c = **p) {
+ for (;; (*p)++, c = **p) {
if (c == 0)
goto finish_force_terminate;
if (!strchr(separators, c))