Open MPI logo

Hardware Locality Development Mailing List Archives

  |   Home   |   Support   |   FAQ   |   all Hardware Locality Development mailing list

Subject: Re: [hwloc-devel] want 1.0rc4?
From: Samuel Thibault (samuel.thibault_at_[hidden])
Date: 2010-05-04 03:56:15


Brice Goglin, le Tue 04 May 2010 07:54:47 +0200, a écrit :
> line 41 of src/misc.c in hwloc_snprintf():
>
> str = malloc(size);
>
>
> I am not sure what to do about this one... Is there any value we could return
> without possibly breaking the caller ?

0 seems relatively safe to me. At worse the caller allocates 0 bytes,
which might also return ENOMEM, but that's up to him to handle it.

Samuel