set missing shm obj index field
authorMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Tue, 23 Aug 2011 19:14:48 +0000 (15:14 -0400)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Tue, 23 Aug 2011 19:14:48 +0000 (15:14 -0400)
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
libringbuffer/shm.c
libust/ltt-ring-buffer-client.h

index 86e8d9184e3c8a3fb066df69e2808028d790fe74..e1dd56f91d0b06afb293a9d8bd601fc158e72845 100644 (file)
@@ -98,8 +98,8 @@ struct shm_object *shm_object_table_append(struct shm_object_table *table,
        obj->memory_map = memory_map;
        obj->memory_map_size = memory_map_size;
        obj->allocated_len = 0;
+       obj->index = table->allocated_len++;
 
-       table->allocated_len++;
        return obj;
 
 error_mmap:
index 3d3bfb5ec5e25818b1bb94a461efa37aabb570cf..697324c799b7ea03a67a05efcb087f48518d7c86 100644 (file)
@@ -381,7 +381,7 @@ struct ltt_channel *_channel_create(const char *name,
        ltt_chan->handle = channel_create(&client_config, name, ltt_chan, buf_addr,
                              subbuf_size, num_subbuf, switch_timer_interval,
                              read_timer_interval);
-       ltt_chan->chan = shmp(handle, handle->chan);
+       ltt_chan->chan = shmp(ltt_chan->handle, ltt_chan->handle->chan);
        return ltt_chan;
 }
 
This page took 0.026254 seconds and 4 git commands to generate.