Some mmap() changes for the OSS emulation.
#include <getopt.h>
#include <fcntl.h>
#include <ctype.h>
+#include <errno.h>
#include <netinet/in.h>
#include <sys/asoundlib.h>
#include "aconfig.h"
char *buf = audiobuf;
while (l > 0) {
while ((r = fcn_write(pcm_handle, buf, l)) < 0) {
+ if (r == -EAGAIN) {
+ r = 0;
+ break;
+ }
playback_write_error();
}
#if 0
}
count -= c;
}
+ if (l == -EAGAIN)
+ l = 0;
if (l < 0) {
fprintf(stderr, "read error: %s\n", snd_strerror(l));
exit(-1);