Version 2.6.7
[lttng-ust.git] / libringbuffer / shm.c
index 90160ce1976c7c7c5a2853eca93229c9b3871460..3bf648d253bd4f00ad8791b34cecb3d75e0c19d2 100644 (file)
@@ -77,6 +77,8 @@ struct shm_object_table *shm_object_table_create(size_t max_nb_obj)
 
        table = zmalloc(sizeof(struct shm_object_table) +
                        max_nb_obj * sizeof(table->objects[0]));
+       if (!table)
+               return NULL;
        table->size = max_nb_obj;
        return table;
 }
@@ -145,7 +147,7 @@ struct shm_object *_shm_object_table_alloc_shm(struct shm_object_table *table,
                 * Using mktemp filename with O_CREAT | O_EXCL open
                 * flags.
                 */
-               mktemp(tmp_name);
+               (void) mktemp(tmp_name);
                if (tmp_name[0] == '\0') {
                        PERROR("mktemp");
                        goto error_shm_open;
This page took 0.025653 seconds and 4 git commands to generate.