mirror of
https://github.com/rtlsdrblog/rtl-sdr-blog.git
synced 2024-11-10 04:37:37 +01:00
Clean out stale data in ring buffer when client disconnects.
This commit is contained in:
parent
d0e7dcde04
commit
da0c8ea073
@ -580,6 +580,10 @@ int main(int argc, char **argv)
|
||||
closesocket(s);
|
||||
|
||||
printf("all threads dead..\n");
|
||||
|
||||
// Clear stale data for next client
|
||||
ringbuf_head = ringbuf_tail = 0;
|
||||
memset(ringbuf, 0, ringbuf_sz);
|
||||
|
||||
do_exit = 0;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user