From owner-svn-src-all@freebsd.org Fri May 20 04:31:46 2016 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 37F85B43639; Fri, 20 May 2016 04:31:46 +0000 (UTC) (envelope-from rpokala@mac.com) Received: from mr11p00im-asmtp003.me.com (mr11p00im-asmtp003.me.com [17.110.69.254]) (using TLSv1.2 with cipher DHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 1DAEC1059; Fri, 20 May 2016 04:31:46 +0000 (UTC) (envelope-from rpokala@mac.com) Received: from process-dkim-sign-daemon.mr11p00im-asmtp003.me.com by mr11p00im-asmtp003.me.com (Oracle Communications Messaging Server 7.0.5.36.0 64bit (built Sep 8 2015)) id <0O7G00F00KJ51900@mr11p00im-asmtp003.me.com>; Fri, 20 May 2016 04:31:45 +0000 (GMT) Received: from [192.168.1.4] (c-67-169-142-6.hsd1.ca.comcast.net [67.169.142.6]) by mr11p00im-asmtp003.me.com (Oracle Communications Messaging Server 7.0.5.36.0 64bit (built Sep 8 2015)) with ESMTPSA id <0O7G00G9LKKWX100@mr11p00im-asmtp003.me.com>; Fri, 20 May 2016 04:31:45 +0000 (GMT) X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2016-05-19_11:,, signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 clxscore=1011 suspectscore=0 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1510270003 definitions=main-1605200057 User-Agent: Microsoft-MacOutlook/f.16.0.160506 Date: Thu, 19 May 2016 21:31:47 -0700 Subject: Re: svn commit: r300258 - head/sys/dev/iicbus From: Ravi Pokala Sender: "Pokala, Ravi" To: Jason Harmening , "Jason A. Harmening" , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-id: Thread-topic: svn commit: r300258 - head/sys/dev/iicbus References: <201605200303.u4K334pG019632@repo.freebsd.org> <371B94E2-E906-4F9C-9A9B-A9D35CD93D21@panasas.com> <573E8CFB.8090007@gmail.com> In-reply-to: <573E8CFB.8090007@gmail.com> MIME-version: 1.0 Content-type: text/plain; charset=UTF-8 Content-transfer-encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mac.com; s=4d515a; t=1463718705; bh=gk9Eu3n3NI0gft6/vw8PzNrlfd23ZGMIspNpUrCRckU=; h=Date:Subject:From:To:Message-id:MIME-version:Content-type; b=oKmChSB7+c7td3VOXud91zslkTakwwBNksDyzDlyOUDfCLF7oiEh6wZkdXEvwHhcS BbGR8dqCmH7zn1mmHNWYLdI5eMrKE6p2anU45Krd1R5/57tV8bi28sgNRp+p5ybu2U pE4FroC2dXSrHli6OxGBFkUrmV9QIBxPDYY8gMVETWgvPd0npWTVuukWTNxhJWSB3P by3LYTbtUxURtUiTNdqBOWEMSNtjq7aSsT/SqOszSTSW8ObZ1/dmRKyAmD6WH3RQJd XU+PPRemMR8tBzOdntmz2n8S/Cw03d+Q0+DB4xlprSII9IXVENkpvm0voFMN9JBgnR iJWxSpfq2iP9A== X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 May 2016 04:31:46 -0000 -----Original Message----- From: Jason Harmening Date: 2016-05-19, Thursday at 21:05 To: Ravi Pokala , "Jason A. Harmening" , = , , Subject: Re: svn commit: r300258 - head/sys/dev/iicbus >On 05/19/16 20:50, Ravi Pokala wrote: >> -----Original Message----- >> From: on behalf of "Jason A. Harmenin= g" >> Date: 2016-05-19, Thursday at 20:03 >> To: , , >> Subject: svn commit: r300258 - head/sys/dev/iicbus >>=20 >> Hi Jason, >>=20 >> If I=E2=80=99m reading that right, it=E2=80=99s not preventing any allocations, but = it is preventing a leak. Is that correct? >>=20 >> Thanks, >>=20 >> Ravi (rpokala@) > >Hi Ravi, > >There shouldn't be a leak in here, but checking the result prevents >falling through the rest of the function, including the unnecessary >malloc of usrbufs right after this. How did I miss that earlier? Time for new glasses! :-P >It also makes the error handling clearer. Yeah. >Thanks, >Jason Thank *you*, Ravi (rpokala@)