Merge pull request #1 from mpereira/fix-alt-linux-unused-result-warning

Fix compilation warning.
This commit is contained in:
greno4ka 2017-11-03 19:19:37 +03:00 committed by GitHub
commit 2f110e9cc3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -129,7 +129,9 @@ void version() {
if (!(version_file = fopen("VERSION", "rb"))) { if (!(version_file = fopen("VERSION", "rb"))) {
tty_solitaire_generic_error(errno, __FILE__, __LINE__); tty_solitaire_generic_error(errno, __FILE__, __LINE__);
} }
if (!fread(version_string, 1, 5, version_file)); if (!fread(version_string, 1, 5, version_file)) {
// TODO: handle this.
}
version_string[5] = '\0'; version_string[5] = '\0';
printf("%s\n", version_string); printf("%s\n", version_string);
fclose(version_file); fclose(version_file);