ref: 08246ee55357da38cb8b16822834e5c610814cca
parent: 135bc14f80c3316dd46e1a365fd98a9d0ed613df
parent: 59109e9711da82c7cf477f485f7b06070a03e3ec
author: Paul Brossier <piem@piem.org>
date: Sun Mar 31 19:12:30 EDT 2019
Merge branch 'feature/sink_vorbis' into feature/autosink
--- a/src/io/sink_vorbis.c
+++ b/src/io/sink_vorbis.c
@@ -119,9 +119,7 @@
s->fid = fopen((const char *)s->path, "wb");
if (!s->fid) {
- char errorstr[256];
- AUBIO_STRERROR(errno, errorstr, sizeof(errorstr));
- AUBIO_ERR("sink_vorbis: Error opening file \'%s\' (%s)\n",
+ AUBIO_STRERR("sink_vorbis: Error opening file \'%s\' (%s)\n",
s->path, errorstr);
return AUBIO_FAIL;
}
@@ -213,9 +211,7 @@
wrote = fwrite(s->og.body, 1, s->og.body_len, s->fid);
result &= (wrote == (unsigned)s->og.body_len);
if (result == 0) {
- char errorstr[256];
- AUBIO_STRERROR(errno, errorstr, sizeof(errorstr));
- AUBIO_ERR("sink_vorbis: failed writing \'%s\' to disk (%s)\n",
+ AUBIO_STRERR("sink_vorbis: failed writing \'%s\' to disk (%s)\n",
s->path, errorstr);
return AUBIO_FAIL;
}
@@ -307,9 +303,7 @@
aubio_sink_vorbis_write(s);
if (s->fid && fclose(s->fid)) {
- char errorstr[256];
- AUBIO_STRERROR(errno, errorstr, sizeof(errorstr));
- AUBIO_ERR("sink_vorbis: Error closing file \'%s\' (%s)\n",
+ AUBIO_STRERR("sink_vorbis: Error closing file \'%s\' (%s)\n",
s->path, errorstr);
return AUBIO_FAIL;
}