From cda36d9c43e2ad9c7362907ff32c9d93aaf3c357 Mon Sep 17 00:00:00 2001 From: Diane Bruce Date: Mon, 24 Jul 2006 19:20:07 +0000 Subject: [PATCH] - Give user a chance to fix from wjst, don't just exit. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/trunk@203 ab8295b8-cf94-4d9e-aec4-7959e3be5d79 --- start_oss.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/start_oss.c b/start_oss.c index c257e960d..2a3335aaa 100644 --- a/start_oss.c +++ b/start_oss.c @@ -112,7 +112,7 @@ start_threads_(int *ndevin, int *ndevout, short y1[], short y2[], if(data.fd_in < 0) { fprintf(stderr, "Cannot open %s for input.\n", dsp_in); - exit(-1); + return (-1); } data.fd_out = data.fd_in; @@ -146,23 +146,23 @@ start_threads_(int *ndevin, int *ndevout, short y1[], short y2[], channels = 2; if(ioctl (data.fd_in, SNDCTL_DSP_CHANNELS, &channels) == -1) { fprintf (stderr, "Unable to set 2 channels for input.\n"); - exit (-1); + return (-1); } if(channels != 2) { fprintf (stderr, "Unable to set 2 channels.\n"); - exit (-1); + return (-1); } format = AFMT_S16_NE; if(ioctl (data.fd_in, SNDCTL_DSP_SETFMT, &format) == -1) { fprintf (stderr, "Unable to set format for input.\n"); - exit (-1); + return (-1); } if(ioctl (data.fd_in, SNDCTL_DSP_SPEED, &rate) == -1) { fprintf (stderr, "Unable to set rate for input\n"); - exit (-1); + return (-1); } printf("Audio OSS streams running normally.\n");