summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--1/23.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/1/23.c b/1/23.c
index b27e60f..2a563cd 100644
--- a/1/23.c
+++ b/1/23.c
@@ -32,7 +32,7 @@ int main(int argc, char *argv[]) {
comment = NONE;
// try not to add redundant line breaks.
if (s[i - 1] != '\n')
- s[i] = '\n';
+ s[i++] = '\n';
} else if (comment == MULTILC && curr == '/' && prev == '*') {
comment = NONE;
}