Closed cboulay closed 3 years ago
Just confirming that I get the same when debugging ReceiveDataC in VS2019 with SendDataC (Debug) running in the background.
First try:
<?xml version="1.0"?>
<info>
<name>SendDataC</name>
<type>EEG</type>
<channel_count>8</channel_count>
<channel_format>float32</channel_format>
<source_id>325wqer4354</source_id>
<nominal_srate>500.0000000000000</nominal_srate>
<version>1.100000000000000</version>
<created_at>36158.48481850000</created_at>
<uid>c4aa7138-e565-4a8f-bddf-39adea3a3b2b</uid>
<session_id>default</session_id>
<hostname>DESKTOP-8HB5T46</hostname>
<v4address />
<v4data_port>16572</v4data_port>
<v4service_port>16572</v4service_port>
<v6address />
<v6data_port>16572</v6data_port>
<v6service_port>16572</v6service_port>
<desc />
</info>
ÍýýýýÝÝÝÝÝÝÝÝÝÝݴжhðo
Second try
<?xml version="1.0"?>
<info>
<name>SendDataC</name>
<type>EEG</type>
<channel_count>8</channel_count>
<channel_format>float32</channel_format>
<source_id>325wqer4354</source_id>
<nominal_srate>500.0000000000000</nominal_srate>
<version>1.100000000000000</version>
<created_at>36158.48481850000</created_at>
<uid>c4aa7138-e565-4a8f-bddf-39adea3a3b2b</uid>
<session_id>default</session_id>
<hostname>DESKTOP-8HB5T46</hostname>
<v4address />
<v4data_port>16572</v4data_port>
<v4service_port>16572</v4service_port>
<v6address />
<v6data_port>16572</v6data_port>
<v6service_port>16572</v6service_port>
<desc />
</info>
ÍýýýýÝÝÝÝÝÝÝÝÝÝÝǪP>yè
It appears to be the same strcpy --> memcpy problem as the other recent issue & reversion.
https://github.com/sccn/liblsl/commit/ece288b60284694f748f36a8db23e8e232bd5519
In this case I fixed it by setting the final value to '\0'. Seems to be OK so far.
I'm using pylsl for my testing, but I don't see how that can be at fault given that I'm just looking at the return of
lib.lsl_get_xml(self.obj)
. Below in the collapsed details are the returns of 5 consecutive calls. Only the 4th appears to be correct. The second seems to have the last few bytes repeated. The others seem to have extra garbage added to the tail.This is with my own tests in some separate software. I repeated the above with
SendDataAdvanced.py
, 2/5 were good, the rest had the same junk appended to the tail.