From 1ef2fb4f10b28baba861357efe2593e2a735ffdf Mon Sep 17 00:00:00 2001 From: Christian Grothoff Date: Wed, 25 Jan 2012 10:23:55 +0000 Subject: -check return value --- src/statistics/gnunet-service-statistics.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/statistics/gnunet-service-statistics.c b/src/statistics/gnunet-service-statistics.c index ec3492710..1d636bd25 100644 --- a/src/statistics/gnunet-service-statistics.c +++ b/src/statistics/gnunet-service-statistics.c @@ -245,7 +245,8 @@ save () if (GNUNET_OK != GNUNET_BIO_write (wh, pos->msg, size)) { GNUNET_log_strerror_file (GNUNET_ERROR_TYPE_WARNING, "write", fn); - GNUNET_BIO_write_close (wh); + if (GNUNET_OK != GNUNET_BIO_write_close (wh)) + GNUNET_log_strerror_file (GNUNET_ERROR_TYPE_WARNING, "close", fn); wh = NULL; } else @@ -255,7 +256,8 @@ save () } if (NULL != wh) { - GNUNET_BIO_write_close (wh); + if (GNUNET_OK != GNUNET_BIO_write_close (wh)) + GNUNET_log_strerror_file (GNUNET_ERROR_TYPE_WARNING, "close", fn); if (total == 0) GNUNET_break (0 == UNLINK (fn)); else -- cgit v1.2.3