pcp
[Top] [All Lists]

Re: [pcp] pcp updates

To: Martin Hicks <mort@xxxxxxxx>
Subject: Re: [pcp] pcp updates
From: Max Matveev <makc@xxxxxxxxx>
Date: Sun, 8 Mar 2009 09:52:26 +1100
Cc: pcp@xxxxxxxxxxx
In-reply-to: <20090307171807.GB6518@xxxxxxxxxxxxxxxxx>
References: <20090306182731.GM30461@xxxxxxxxxxxxxxxxxxxxxxxxx> <18866.31663.926735.91528@xxxxxxxxxxxxxxxxx> <20090307171807.GB6518@xxxxxxxxxxxxxxxxx>
On Sat, 7 Mar 2009 12:18:07 -0500, Martin Hicks wrote:

 mort> On Sun, Mar 08, 2009 at 12:50:39AM +1100, Max Matveev wrote:
 >> On Fri, 6 Mar 2009 12:27:31 -0600, Martin Hicks wrote:
 >> 
 >> Strictly speaking you cannot rely on umad_release_port() not to stuff
 >> ca_name and portnum, the fact that it does not do it now, just like
 >> the fact that it didn't do any allocation at all in 1.2 timeframe,
 >> does not mean you're not going to get into some weird use-after-free
 >> next time OFED people change the library.

 mort> I realize that I'm exploiting a particular behaviour in the ibumad
 mort> library.  I've also filed a bug against the ibumad library and hopefully
 mort> someone will fix that in a future release.
You can add ca_name and portnum into the local_port_t and make release/get
independent of the shenanigans of libibumad.

 mort> As it stands now, I had a machine with about 300MB of leaked memory over
 mort> 25 days due to this bug.
I agree that there is a bug, I just don't thing the fix is the right
one.

 >> PS. And it's tabs, not spaces for indentation.

 mort> It looks like the file is using a mix of tabs and spaces.
Basic offset (a unit of indentation) is 4 spaces, 2 basic units are
converted to a tab.

In vi it's

set shiftwdith=4
set tabspace=8

max

<Prev in Thread] Current Thread [Next in Thread>