X-Git-Url: https://git.lttng.org/?a=blobdiff_plain;f=src%2Fbin%2Flttng-relayd%2Ftracefile-array.cpp;fp=src%2Fbin%2Flttng-relayd%2Ftracefile-array.cpp;h=07d5ee17f2f2c7a3f97eba57b4bfa76171569e45;hb=28ab034a2c3582d07d3423d2d746731f87d3969f;hp=73a2887941517275c4a860e89f71dab92585f3c8;hpb=52e345b9ac912d033c2a2c25a170a01cf209839d;p=lttng-tools.git diff --git a/src/bin/lttng-relayd/tracefile-array.cpp b/src/bin/lttng-relayd/tracefile-array.cpp index 73a288794..07d5ee17f 100644 --- a/src/bin/lttng-relayd/tracefile-array.cpp +++ b/src/bin/lttng-relayd/tracefile-array.cpp @@ -6,11 +6,11 @@ */ #define _LGPL_SOURCE +#include "tracefile-array.hpp" + #include -#include #include - -#include "tracefile-array.hpp" +#include struct tracefile_array *tracefile_array_create(size_t count) { @@ -67,8 +67,7 @@ void tracefile_array_reset(struct tracefile_array *tfa) tfa->file_tail = 0; } -void tracefile_array_file_rotate(struct tracefile_array *tfa, - enum tracefile_rotate_type type) +void tracefile_array_file_rotate(struct tracefile_array *tfa, enum tracefile_rotate_type type) { uint64_t *headp, *tailp; @@ -109,8 +108,7 @@ void tracefile_array_file_rotate(struct tracefile_array *tfa, } } -void tracefile_array_commit_seq(struct tracefile_array *tfa, - uint64_t new_seq_head) +void tracefile_array_commit_seq(struct tracefile_array *tfa, uint64_t new_seq_head) { uint64_t *headp, *tailp; @@ -157,8 +155,7 @@ uint64_t tracefile_array_get_seq_tail(struct tracefile_array *tfa) return tfa->seq_tail; } -bool tracefile_array_seq_in_file(struct tracefile_array *tfa, - uint64_t file_index, uint64_t seq) +bool tracefile_array_seq_in_file(struct tracefile_array *tfa, uint64_t file_index, uint64_t seq) { if (!tfa->count) { /* @@ -171,8 +168,7 @@ bool tracefile_array_seq_in_file(struct tracefile_array *tfa, if (seq == -1ULL) { return false; } - if (seq >= tfa->tf[file_index].seq_tail - && seq <= tfa->tf[file_index].seq_head) { + if (seq >= tfa->tf[file_index].seq_tail && seq <= tfa->tf[file_index].seq_head) { return true; } else { return false;