From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andrew Cooper Subject: Re: Leaks in xc_tbuf_get_size() (Was: Re: New Defects reported by Coverity Scan for XenProject) Date: Wed, 3 Feb 2016 10:42:20 +0000 Message-ID: <56B1D98C.7030209@citrix.com> References: <56b180c017d5f_214fb5b3143623f@ss1435.mail> <1454495825.25207.50.camel@citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1454495825.25207.50.camel@citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Ian Campbell , George Dunlap Cc: xen-devel List-Id: xen-devel@lists.xenproject.org On 03/02/16 10:37, Ian Campbell wrote: > George, > > Looks like xentrace is the only maintained component which uses this. so > tag ;-) > > On Tue, 2016-02-02 at 20:23 -0800, scan-admin@coverity.com wrote: >> * CID 1351228: (RESOURCE_LEAK) >> /tools/libxc/xc_tbuf.c: 73 in xc_tbuf_get_size() >> /tools/libxc/xc_tbuf.c: 77 in xc_tbuf_get_size() > Coverity is reporting these as new in 41b0aa569adb..9937763265d9 although > the file hasn't changed. However it does look correct that t_info is being > leaked by various paths in this function. It is "new"ly spotted because xc_map_foreign_range() is now a straight function call rather than a function pointer pointing at functions with different behaviours. ~Andrew