[ofa-general] Re: [PATCH] opensm/osm_ucast_lash.c: Eliminate possible seg fault in get_osm_switch_from_port

Hal Rosenstock hal.rosenstock at gmail.com
Tue Jul 14 08:52:20 PDT 2009


On Tue, Jul 14, 2009 at 10:53 AM, Sasha Khapyorsky<sashak at voltaire.com> wrote:
> On 07:03 Tue 14 Jul     , Hal Rosenstock wrote:
>> >
>> > It is what I asked - why is NULL pointer used there (in SA PathRecord
>> > flow) and is is legal usage?
>>
>> It shouldn't be a valid use case.
>
> So why do we need this patch then?

How about a CL_ASSERT there ?

>
>> > As far as I can see in osm_sa_path_record.c it should be impossible, but
>> > maybe I'm missing something.
>>
>> Yes, that's what I thought too but apparently it doesn't appear to be
>> the case and I'm not sure how that could occur. Any ideas ?
>
> If you are able to reproduce such case try to find why this happens
> (crash OpenSM into gdb)

I put core into gdb but it doesn't show how p_port became NULL and
test time to recreate is not easy to get but it's on the list...

-- Hal

> - to hide bugs is not a good idea IMO.

> Sasha
>



More information about the general mailing list