1
0
Fork 0
mirror of https://git.rwth-aachen.de/acs/public/villas/node/ synced 2025-03-09 00:00:00 +01:00

sample: remove source field

This commit is contained in:
Steffen Vogel 2018-08-02 11:28:52 +02:00
parent 2361964de1
commit 7c939ba1e5
5 changed files with 0 additions and 9 deletions

View file

@ -72,8 +72,6 @@ struct sample {
int capacity; /**< The number of values in sample::values for which memory is reserved. */
int flags; /**< Flags are used to store binary properties of a sample. */
struct node *source; /**< The node from which this sample originates. */
struct node *destination; /**< The node to which this sample will be sent. */
atomic_int refcnt; /**< Reference counter. */
ptrdiff_t pool_off; /**< This sample belongs to this memory pool (relative pointer). See sample_pool(). */

View file

@ -113,9 +113,6 @@ static int json_reserve_pack_sample(struct io *io, json_t **j, struct sample *sm
#else
if (io->output.node)
json_object_set_new(*j, "target", json_string(io->output.node->name));
if (smp->source)
json_object_set_new(*j, "origin", json_string(smp->source->name));
#endif
return 0;

View file

@ -355,7 +355,6 @@ int mapping_remap(struct list *m, struct sample *remapped, struct sample *origin
/* We copy all the header fields */
remapped->sequence = original->sequence;
remapped->source = original->source;
remapped->ts = original->ts;
for (size_t i = 0; i < list_length(m); i++) {

View file

@ -437,8 +437,6 @@ int node_read(struct node *n, struct sample *smps[], unsigned cnt, unsigned *rel
/* Add missing fields */
for (int i = 0; i < nread; i++) {
smps[i]->source = n;
if (!(smps[i]->flags & SAMPLE_HAS_SEQUENCE))
smps[i]->sequence = n->sequence++;

View file

@ -148,7 +148,6 @@ int sample_copy(struct sample *dst, struct sample *src)
dst->length = MIN(src->length, dst->capacity);
dst->sequence = src->sequence;
dst->source = src->source;
dst->flags = src->flags;
dst->ts = src->ts;