Your file names are not actually being truncated. Here, `ffmpeg` is trying to read commands from its input stream. Unfortunately, this is the same stream `read` is using to determine filenames, so it appears that parts of these filenames are not being read. To fix this, you should tell `ffmpeg` to disable interaction on the input stream with the `-nostdin` flag.