--- sourceforge.net/trunk/rdesktop/rdpsnd_sun.c 2003/10/23 11:11:31 510 +++ sourceforge.net/trunk/rdesktop/rdpsnd_sun.c 2003/12/11 15:07:04 561 @@ -26,7 +26,10 @@ #include #include #include + +#if (defined(sun) && (defined(__svr4__) || defined(__SVR4))) #include +#endif #define MAX_QUEUE 10 @@ -80,8 +83,13 @@ queue_lo = (queue_lo + 1) % MAX_QUEUE; } +#if defined I_FLUSH && defined FLUSHW /* Flush the audiobuffer */ ioctl(g_dsp_fd, I_FLUSH, FLUSHW); +#endif +#if defined AUDIO_FLUSH + ioctl(g_dsp_fd, AUDIO_FLUSH, NULL); +#endif close(g_dsp_fd); } @@ -124,11 +132,11 @@ if (pwfx->nChannels == 1) { - info.play.channels = AUDIO_CHANNELS_MONO; + info.play.channels = 1; } else if (pwfx->nChannels == 2) { - info.play.channels = AUDIO_CHANNELS_STEREO; + info.play.channels = 2; g_samplewidth *= 2; }