1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-06-28 14:18:41 +02:00

Bug1829, more: detect out-of-space when writing FFmpeg formats

This commit is contained in:
Paul Licameli 2018-01-23 07:57:52 -05:00
parent f4c8920e23
commit 58e4823f68

View File

@ -176,7 +176,10 @@ static int ufile_read(void *opaque, uint8_t *buf, int size)
static int ufile_write(void *opaque, uint8_t *buf, int size)
{
return (int) ((wxFile *) opaque)->Write(buf, size);
auto bytes = (int) ((wxFile *) opaque)->Write(buf, size);
if (bytes != size)
return -ENOSPC;
return bytes;
}
static int64_t ufile_seek(void *opaque, int64_t pos, int whence)