From f8d9ff23eb8d3e3286ff5cf4d5f9493532991bb7 Mon Sep 17 00:00:00 2001 From: zlg Date: Thu, 16 Jun 2016 10:15:33 -0700 Subject: The massive astyle sweep! Code style should be consistent now. All future commits will be run through astyle or they will be amended. --- ch1/1-18_strip-blanks.c | 3 --- 1 file changed, 3 deletions(-) (limited to 'ch1/1-18_strip-blanks.c') diff --git a/ch1/1-18_strip-blanks.c b/ch1/1-18_strip-blanks.c index 947ce8d..2074129 100644 --- a/ch1/1-18_strip-blanks.c +++ b/ch1/1-18_strip-blanks.c @@ -14,7 +14,6 @@ int get_line(char s[], int lim) { int c, i; - for (i = 0; i < lim - 1 && (c = getchar()) != EOF && c != '\n'; ++i) { s[i] = c; } @@ -29,7 +28,6 @@ int get_line(char s[], int lim) { int main(void) { char buffer[MAXLINELENGTH]; int c, i, len; - /* Make sure every line is gone over */ while (len = get_line(buffer, MAXLINELENGTH)) { /* An empty for statement, simply to change the i variable. @@ -37,7 +35,6 @@ int main(void) { * string terminator. */ for (i = len - 2; (i > 0) && (buffer[i] == ' ') || (buffer[i] == '\t'); --i); - /* We've reached the end of the line's actual content. Terminate the line. */ if (i >= 1) { buffer[i + 1] = '\n'; -- cgit v1.2.3-54-g00ecf