/[rdesktop]/sourceforge.net/trunk/rdesktop/rdpsnd_oss.c
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /sourceforge.net/trunk/rdesktop/rdpsnd_oss.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1375 by jsorg71, Mon Jan 8 04:47:06 2007 UTC revision 1376 by ossman_, Wed Jan 10 09:15:15 2007 UTC
# Line 49  static int dsp_mode; Line 49  static int dsp_mode;
49  static int dsp_refs;  static int dsp_refs;
50    
51  static RD_BOOL dsp_configured;  static RD_BOOL dsp_configured;
52    static RD_BOOL dsp_broken;
53    
54  static RD_BOOL dsp_out;  static RD_BOOL dsp_out;
55  static RD_BOOL dsp_in;  static RD_BOOL dsp_in;
# Line 131  oss_open(int fallback) Line 132  oss_open(int fallback)
132          }          }
133    
134          dsp_configured = False;          dsp_configured = False;
135            dsp_broken = False;
136    
137          dsp_mode = O_RDWR;          dsp_mode = O_RDWR;
138          dsp_fd = open(dsp_dev, O_RDWR | O_NONBLOCK);          dsp_fd = open(dsp_dev, O_RDWR | O_NONBLOCK);
# Line 389  oss_play(void) Line 391  oss_play(void)
391          if (len == -1)          if (len == -1)
392          {          {
393                  if (errno != EWOULDBLOCK)                  if (errno != EWOULDBLOCK)
394                          perror("write audio");                  {
395                            if (!dsp_broken)
396                                    perror("RDPSND: write()");
397                            dsp_broken = True;
398                            rdpsnd_queue_next(0);
399                    }
400                  return;                  return;
401          }          }
402    
403            dsp_broken = False;
404    
405          out->p += len;          out->p += len;
406    
407          if (out->p == out->end)          if (out->p == out->end)
# Line 441  oss_record(void) Line 450  oss_record(void)
450          if (len == -1)          if (len == -1)
451          {          {
452                  if (errno != EWOULDBLOCK)                  if (errno != EWOULDBLOCK)
453                          perror("read audio");                  {
454                            if (!dsp_broken)
455                                    perror("RDPSND: read()");
456                            dsp_broken = True;
457                            rdpsnd_queue_next(0);
458                    }
459                  return;                  return;
460          }          }
461    
462            dsp_broken = False;
463    
464          rdpsnd_record(buffer, len);          rdpsnd_record(buffer, len);
465  }  }
466    

Legend:
Removed from v.1375  
changed lines
  Added in v.1376

  ViewVC Help
Powered by ViewVC 1.1.26