Good catch; thanks. r166.
On Mar 14, 2008, at 11:42 AM, Bert Wesarg wrote:
> There is a missing clear_cache() in case a malloc() failed in
> load_cache().
>
> Bye
> Bert
>
> ---
> diff --git a/src/libplpa/plpa_map.c b/src/libplpa/plpa_map.c
> index 1681640..9551e4a 100644
> --- a/src/libplpa/plpa_map.c
> +++ b/src/libplpa/plpa_map.c
> @@ -204,6 +204,7 @@ static void load_cache(const char *sysfs_mount)
> map_processor_id_to_tuple = malloc(sizeof(tuple_t) *
> (max_processor_num + 2));
> if (NULL == map_processor_id_to_tuple) {
> + clear_cache();
> return;
> }
> for (i = 0; i <= max_processor_num; ++i) {
> _______________________________________________
> plpa-users mailing list
> plpa-users_at_[hidden]
> http://www.open-mpi.org/mailman/listinfo.cgi/plpa-users
--
Jeff Squyres
Cisco Systems
|