Remove clearly broken error checking, as pointed out by newer gcc.
Note that the error checking is probably useful if done correctly, but I have no way to test this, so just removing the offending code is the only way forward. Thanks to the fairly creative bug, the code did nothing at all anyway. Change-Id: Ifeef57202f31e842ca1befa331f8b34e1c76757c
This commit is contained in:
parent
2c7bb67302
commit
b58b9c26c9
1 changed files with 1 additions and 17 deletions
|
@ -1261,13 +1261,6 @@ read_comment_sgf (char *buffer, size_t buffer_size)
|
|||
return -1;
|
||||
}
|
||||
|
||||
if (!read_char_no_whitespace (unhandled_fd) == 'C' ||
|
||||
!read_char_no_whitespace (unhandled_fd) == '[')
|
||||
{
|
||||
DEBUGF ("comment prop points to incorrect place in unhandled_fd!!\n");
|
||||
return -1;
|
||||
}
|
||||
|
||||
/* make output a string, the lazy way */
|
||||
rb->memset (buffer, 0, buffer_size);
|
||||
++bytes_read;
|
||||
|
@ -1358,16 +1351,7 @@ write_comment_sgf (char *string)
|
|||
|
||||
start_of_write_wcs:
|
||||
|
||||
if (overwriting)
|
||||
{
|
||||
if (!read_char_no_whitespace (unhandled_fd) == 'C' ||
|
||||
!read_char_no_whitespace (unhandled_fd) == '[')
|
||||
{
|
||||
DEBUGF ("non-comment while overwriting!!\n");
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
else
|
||||
if (!overwriting)
|
||||
{
|
||||
start_of_comment = rb->lseek (unhandled_fd, 0, SEEK_END);
|
||||
|
||||
|
|
Loading…
Reference in a new issue