From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 93212 invoked by alias); 26 May 2017 10:37:00 -0000 Mailing-List: contact newlib-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: newlib-owner@sourceware.org Received: (qmail 93198 invoked by uid 89); 26 May 2017 10:36:59 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD,SPF_HELO_PASS autolearn=ham version=3.3.2 spammy=UD:write.c, H*f:sk:VatPOvJ, H*f:sk:iQRwBjf, writec X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 26 May 2017 10:36:58 +0000 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id E15E67F3FA; Fri, 26 May 2017 10:37:00 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com E15E67F3FA Authentication-Results: ext-mx01.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx01.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=nickc@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com E15E67F3FA Received: from [10.36.117.1] (ovpn-117-1.ams2.redhat.com [10.36.117.1]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 01A7978C28; Fri, 26 May 2017 10:36:59 +0000 (UTC) Subject: Re: [PATCH][MSP430] Fix return code error in simulator implemenations of write.c. To: Martin Young , newlib@sourceware.org References: From: Nick Clifton Message-ID: <325261e1-2f1f-d00b-fbc1-673a65226fbb@redhat.com> Date: Fri, 26 May 2017 10:37:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.1.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-IsSubscribed: yes X-SW-Source: 2017/txt/msg00367.txt.bz2 Hi Martin, > In the MSP430 simulator implementation of write() in write.c the wrong > local is used as the return code (it's returning the result of the > last invocation of write_chunk() (variable c) rather than the > aggregate write size (variable rv). This causes issues for users of > write(). > > Patch included as attachment to avoid whitespace issues. Thanks very much for reporting this problem, and for providing a fix. I have checked your patch in, so the write() function should work properly from now on. Cheers Nick