From patchwork Sun Dec 20 01:39:12 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Kirill A . Shutemov" X-Patchwork-Id: 41489 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 1237CB6F16 for ; Sun, 20 Dec 2009 12:43:07 +1100 (EST) Received: from localhost ([127.0.0.1]:36736 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NMAp6-0000uE-50 for incoming@patchwork.ozlabs.org; Sat, 19 Dec 2009 20:43:04 -0500 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NMAls-0007oK-2G for qemu-devel@nongnu.org; Sat, 19 Dec 2009 20:39:44 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NMAlm-0007fO-P1 for qemu-devel@nongnu.org; Sat, 19 Dec 2009 20:39:43 -0500 Received: from [199.232.76.173] (port=54469 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NMAlm-0007fE-Mh for qemu-devel@nongnu.org; Sat, 19 Dec 2009 20:39:38 -0500 Received: from mail-fx0-f222.google.com ([209.85.220.222]:53674) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NMAlm-0004mU-Bw for qemu-devel@nongnu.org; Sat, 19 Dec 2009 20:39:38 -0500 Received: by mail-fx0-f222.google.com with SMTP id 22so4042055fxm.2 for ; Sat, 19 Dec 2009 17:39:38 -0800 (PST) Received: by 10.223.127.195 with SMTP id h3mr6324959fas.57.1261273177858; Sat, 19 Dec 2009 17:39:37 -0800 (PST) Received: from localhost.localdomain (a88-114-220-92.elisa-laajakaista.fi [88.114.220.92]) by mx.google.com with ESMTPS id 13sm6982256fks.45.2009.12.19.17.39.36 (version=SSLv3 cipher=RC4-MD5); Sat, 19 Dec 2009 17:39:37 -0800 (PST) From: "Kirill A. Shutemov" To: qemu-devel@nongnu.org Date: Sun, 20 Dec 2009 03:39:12 +0200 Message-Id: <1261273167-3240-3-git-send-email-kirill@shutemov.name> X-Mailer: git-send-email 1.6.5.6 In-Reply-To: <1261273167-3240-2-git-send-email-kirill@shutemov.name> References: <1261273167-3240-1-git-send-email-kirill@shutemov.name> <1261273167-3240-2-git-send-email-kirill@shutemov.name> X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 2) Cc: "Kirill A. Shutemov" Subject: [Qemu-devel] [PATCH 03/18] posix-aio-compat.c: fix warning with _FORTIFY_SOURCE X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org CC posix-aio-compat.o cc1: warnings being treated as errors posix-aio-compat.c: In function 'aio_signal_handler': posix-aio-compat.c:505: error: ignoring return value of 'write', declared with attribute warn_unused_result make: *** [posix-aio-compat.o] Error 1 Signed-off-by: Kirill A. Shutemov --- posix-aio-compat.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/posix-aio-compat.c b/posix-aio-compat.c index dc14f53..555e263 100644 --- a/posix-aio-compat.c +++ b/posix-aio-compat.c @@ -502,7 +502,8 @@ static void aio_signal_handler(int signum) if (posix_aio_state) { char byte = 0; - write(posix_aio_state->wfd, &byte, sizeof(byte)); + if (write(posix_aio_state->wfd, &byte, sizeof(byte)) != sizeof(byte)) + die("write()"); } qemu_service_io();