diff options
| author | Colin Walters | 2002-04-23 20:23:05 +0000 |
|---|---|---|
| committer | Colin Walters | 2002-04-23 20:23:05 +0000 |
| commit | 1d4328ffce9fefc5015fe24368ea73a527d0f646 (patch) | |
| tree | fc43a01a0709a80f1376a0e029a67c52129f7e61 | |
| parent | cba128915b6d44217186adc041946cb32d0a95b4 (diff) | |
| download | emacs-1d4328ffce9fefc5015fe24368ea73a527d0f646.tar.gz emacs-1d4328ffce9fefc5015fe24368ea73a527d0f646.zip | |
(read_score) [HAVE_GETDELIM]: Trim trailing space.
| -rw-r--r-- | lib-src/update-game-score.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib-src/update-game-score.c b/lib-src/update-game-score.c index 110c6a9e605..0762956a701 100644 --- a/lib-src/update-game-score.c +++ b/lib-src/update-game-score.c | |||
| @@ -254,6 +254,8 @@ read_score(FILE *f, struct score_entry *score) | |||
| 254 | if (getdelim(&score->username, &count, ' ', f) < 1 | 254 | if (getdelim(&score->username, &count, ' ', f) < 1 |
| 255 | || score->username == NULL) | 255 | || score->username == NULL) |
| 256 | return -1; | 256 | return -1; |
| 257 | /* Trim the space */ | ||
| 258 | score->username[strlen(score->username)-1] = '\0'; | ||
| 257 | } | 259 | } |
| 258 | #else | 260 | #else |
| 259 | { | 261 | { |