mirror of
https://git.rwth-aachen.de/acs/public/villas/node/
synced 2025-03-09 00:00:00 +01:00
capi: fix memcpy error
This commit is contained in:
parent
82fe40ee1c
commit
6d299d33ed
1 changed files with 2 additions and 2 deletions
|
@ -209,7 +209,7 @@ vsample * sample_pack(unsigned seq, struct timespec *ts_origin, struct timespec
|
|||
smp->length = len;
|
||||
smp->flags = (int) SampleFlags::HAS_SEQUENCE | (int) SampleFlags::HAS_DATA | (int) SampleFlags::HAS_TS_ORIGIN;
|
||||
|
||||
memcpy(smp->data, values, sizeof(double)*len);
|
||||
memcpy((double *) smp->data, values, sizeof(double) * len);
|
||||
|
||||
return (vsample *) smp;
|
||||
}
|
||||
|
@ -226,7 +226,7 @@ void sample_unpack(vsample *s, unsigned *seq, struct timespec *ts_origin, struct
|
|||
*flags =smp->flags;
|
||||
*len = smp->length;
|
||||
|
||||
memcpy(values, smp->data, sizeof(double)* *len);
|
||||
memcpy(values, (double *) smp->data, sizeof(double) * *len);
|
||||
}
|
||||
|
||||
void sample_decref(vsample *smp)
|
||||
|
|
Loading…
Add table
Reference in a new issue