Fix: Move offset endianness conversion to get_data_packet
authorJérémie Galarneau <jeremie.galarneau@efficios.com>
Tue, 25 Feb 2014 20:47:39 +0000 (15:47 -0500)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Tue, 25 Feb 2014 20:50:59 +0000 (15:50 -0500)
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
formats/lttng-live/lttng-live-comm.c

index 5a7d067e4cd55127c539b91b5bc169cebd8d772e..e3cab91457fbf8ee2b6316a9bc4b31ad6143c7e6 100644 (file)
@@ -631,8 +631,7 @@ retry:
 
        memset(&rq, 0, sizeof(rq));
        rq.stream_id = htobe64(stream->id);
-       /* Already in big endian. */
-       rq.offset = offset;
+       rq.offset = htobe64(offset);
        rq.len = htobe32(len);
 
        ret_len = lttng_live_send(ctx->control_sock, &cmd, sizeof(cmd));
@@ -1110,7 +1109,7 @@ retry:
        printf_verbose("get_data_packet for stream %" PRIu64 "\n",
                        viewer_stream->id);
        ret = get_data_packet(session->ctx, pos, viewer_stream,
-                       be64toh(cur_index->offset),
+                       cur_index->offset,
                        cur_index->packet_size / CHAR_BIT);
        if (ret == -2) {
                goto retry;
This page took 0.024538 seconds and 4 git commands to generate.