bytes = btr_next_buffer(btrn, &data);
if (ret < 0 || bytes < wn->min_iqs) { /* eof */
assert(btr_no_parent(btrn));
- ret = -E_ALSA_EOF;
+ ret = -E_WRITE_COMMON_EOF;
if (!pad)
goto err;
/* wait until pending frames are played */
PARA_ERROR(BAD_SAMPLE_FORMAT, "sample format not supported"), \
PARA_ERROR(BAD_CHANNEL_COUNT, "channel count not supported"), \
PARA_ERROR(BAD_SAMPLERATE, "sample rate not supported"), \
- PARA_ERROR(OSS_EOF, "oss: end of file"), \
#define COMPRESS_FILTER_ERRORS \
PARA_ERROR(SET_RATE, "snd_pcm_hw_params_set_rate_near failed"), \
PARA_ERROR(START_THRESHOLD, "snd_pcm_sw_params_set_start_threshold() failed"), \
PARA_ERROR(STOP_THRESHOLD, "snd_pcm_sw_params_set_stop_threshold() failed"), \
- PARA_ERROR(ALSA_EOF, "alsa: end of file"), \
-
#define WRITE_COMMON_ERRORS \
PARA_ERROR(WRITE_COMMON_SYNTAX, "syntax error in write option"), \
+ PARA_ERROR(WRITE_COMMON_EOF, "end of file"), \
#define AACDEC_FILTER_ERRORS \
bytes = btr_next_buffer(btrn, &data);
frames = bytes / powd->bytes_per_frame;
if (!frames) { /* eof and less than a single frame available */
- ret = -E_OSS_EOF;
+ ret = -E_WRITE_COMMON_EOF;
goto out;
}
ret = 0;
s->default_timeout.tv_sec = 10;
s->default_timeout.tv_usec = 50000;
ret = schedule(s);
+ if (ret >= 0) {
+ int j;
+ for (j = 0; j < i; j++) {
+ struct task *t = &wns[j].task;
+ assert(t->error < 0);
+ if (t->error != -E_WRITE_COMMON_EOF
+ && t->error != -E_BTR_EOF) {
+ PARA_ERROR_LOG("%s: %s\n", t->status,
+ para_strerror(-t->error));
+ if (ret >= 0)
+ ret = t->error;
+ }
+ }
+ }
out:
for (i--; i >= 0; i--) {
struct writer_node *wn = wns + i;