[openib-general] Re: [PATCH] Unnecessary initialization of sa_query in failure case.

Krishna Kumar krkumar at us.ibm.com
Tue Nov 9 15:31:44 PST 2004


On Tue, 9 Nov 2004, Roland Dreier wrote:

> Why is this initialization unnecessary?  If we delete these lines then
> sa_query is left pointing to invalid memory when a send fails?

Because ULP's should not use a pointers to-be-set-in-callee routines
if the call failed. In this case, path_rec_start and unicast_arp_start
should not use "query" if the call failed. And "query" is a stack
variable in those routines, so it won't hang around too long :-)

thanks,

- KK




More information about the general mailing list