More diagnostics. Fixed shm use.

This commit is contained in:
Abramo Bagnara 2000-10-14 19:43:14 +00:00
parent a380edd64f
commit 03f9565ef8
8 changed files with 157 additions and 130 deletions

View file

@ -347,8 +347,10 @@ int snd_pcm_file_open(snd_pcm_t **pcmp, char *name, char *fname, int fd, snd_pcm
assert(pcmp && slave);
if (fname) {
fd = open(fname, O_WRONLY|O_CREAT, 0666);
if (fd < 0)
if (fd < 0) {
SYSERR("open %s failed", fname);
return -errno;
}
}
file = calloc(1, sizeof(snd_pcm_file_t));
if (!file) {