Start streaming of sound/SDR just before main loop
This prevents buffer overflow during init/creation processes
This commit is contained in:
@@ -475,8 +475,6 @@ void main_common(int *quit, int latency, int interval, void (*myhandler)(void))
|
||||
/* open audio */
|
||||
if (sender_open_audio())
|
||||
return;
|
||||
|
||||
/* afterwards open call audio, because we cannot wait for SDR to open */
|
||||
if (call_open_audio())
|
||||
return;
|
||||
|
||||
@@ -506,6 +504,12 @@ void main_common(int *quit, int latency, int interval, void (*myhandler)(void))
|
||||
signal(SIGTERM, sighandler);
|
||||
signal(SIGPIPE, sighandler);
|
||||
|
||||
/* start streaming */
|
||||
if (sender_start_audio())
|
||||
*quit = 1;
|
||||
if (call_start_audio())
|
||||
*quit = 1;
|
||||
|
||||
while(!(*quit)) {
|
||||
begin_time = get_time();
|
||||
|
||||
|
Reference in New Issue
Block a user