Changed hard-coded 8 to sizeof(double)
This commit is contained in:
parent
1a22a33c0f
commit
3681e7adac
@ -26,7 +26,9 @@ DaqData::DaqData(const us nframes, const us nchannels,
|
||||
DEBUGTRACE_PRINT(sw);
|
||||
|
||||
assert(sw > 0 && sw <= 8);
|
||||
_data = reinterpret_cast<byte_t*>(new double[(sw * nchannels * nframes)/8 + 1]);
|
||||
_data = reinterpret_cast<byte_t *>(
|
||||
new double[(sw * nchannels * nframes) / sizeof(double) + 1]);
|
||||
|
||||
if (!_data) {
|
||||
throw rte("Could not allocate memory for DaqData!");
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user