Suppress -Wunused-result warning about write()

This is related to aa90e148ca, but this
code is only used under -DLINUX_OOM_ADJ, so it was apparently
overlooked then.
This commit is contained in:
Peter Eisentraut 2012-05-27 22:35:01 +03:00
parent a8b92b6090
commit 27314d32a8
1 changed files with 3 additions and 1 deletions

View File

@ -87,9 +87,11 @@ fork_process(void)
if (fd >= 0)
{
char buf[16];
int rc;
snprintf(buf, sizeof(buf), "%d\n", LINUX_OOM_ADJ);
(void) write(fd, buf, strlen(buf));
rc = write(fd, buf, strlen(buf));
(void) rc;
close(fd);
}
}