channel_format_t has the wrong size
tstenner opened this issue · comments
Tristan Stenner commented
Found by @koehil in sccn/liblsl#83 (comment)
The C API doesn't specify a size for lsl_channel_format_t
, but all compilers I checked (GCC / Clang on Linux, MSVC 14.22 on Windows x86_64) assume it's 4 bytes wide (and even if they don't, on most architectures the parameter is widened to 4 bytes when passing it to the function, e.g. by MSVC).
So, the enumshere should be a 4 byte integers, not bytes.