diff options
author | Markus Uhlin <markus@nifty-networks.net> | 2023-12-27 21:57:51 +0100 |
---|---|---|
committer | Markus Uhlin <markus@nifty-networks.net> | 2023-12-27 21:57:51 +0100 |
commit | ac624049dae3226ab399c817c41f30d9f8f3962b (patch) | |
tree | 8e21c4c353b7922c975bbc70875842e2efdd1170 | |
parent | f19d991e099b0fc2253c7627cf76112d77a52c1d (diff) |
Reformatted functions
-rw-r--r-- | FICS/formula.c | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/FICS/formula.c b/FICS/formula.c index 6ee632a..8abdc32 100644 --- a/FICS/formula.c +++ b/FICS/formula.c @@ -66,24 +66,24 @@ extern player parray[]; -PRIVATE char *GetPlayersFormula (player *pWho, int clause) +PRIVATE char * +GetPlayersFormula(player *pWho, int clause) { - if (clause==MAX_FORMULA) return (pWho->formula); - else return (pWho->formulaLines[clause]); + if (clause == MAX_FORMULA) + return pWho->formula; + return pWho->formulaLines[clause]; } -/* In MoveIndexPastString, *i is treated as the index into string[]; - this function returns 1 if the character string beginning with - string[*i] match *text, and 0 otherwise. In the former case, *i - is incremented to move the index past *text. -*/ -int MoveIndexPastString (char *string, int *i, char *text) +int +MoveIndexPastString(char *string, int *i, char *text) { - int n = strlen(text); - if (strncasecmp(text, string + *i, n)) return (0); - *i += n; - return (n); -} /* end of function MoveIndexPastString. */ + int n = strlen(text); + + if (strncasecmp(text, string + *i, n)) + return 0; + *i += n; + return n; +} int GetRating(player *p, int gametype) |