demo/ao_mmap: remove msync() call

The msync() call doesn't seem to work on Comedi devices, and seems a bit
pointless anyway, as it is meant for use on files with a backing store.
Remove it.
This commit is contained in:
Ian Abbott 2013-11-08 13:06:38 +00:00
parent 5f3b60573e
commit 1f0020e108

View file

@ -137,11 +137,6 @@ int main(int argc, char *argv[])
}
num_samples = size / sizeof(sampl_t);
write_waveform(map, num_samples, amplitude, offset, maxdata);
if(msync(map, size, MS_SYNC) < 0)
{
perror("msync");
exit(1);
}
printf("marking %i samples as written\n", num_samples);
ret = comedi_mark_buffer_written(dev, options.subdevice, size);
if(ret < 0)