FFmpeg concat: "Unsafe file name"

Linux howto's, compile information, information on whatever we learned on working with linux, MACOs and - of course - Products of the big evil....
Post Reply
User avatar
peter_b
Chatterbox
Posts: 370
Joined: Tue Nov 12, 2013 2:05 am

FFmpeg concat: "Unsafe file name"

Post by peter_b »

[PROBLEM]
Using FFmpeg's concat filter to join segmented video files.
However, recently I ran into this error message:
[concat @ 0x5488ec0] Unsafe file name '/some/folder/somewhere/dva-test-000.avi'
/dev/fd/63: Operation not permitted
[SOLUTION]
Since Feburary 2013, it seems that absolute filepaths are considered non-safe for the concat filter.

Either use relative paths or add "-safe 0" as option to the concat filter.
Like this, for example:

Code: Select all

$ ffmpeg -f concat -safe 0 -i <(for f in ./*.avi; do echo "file '$PWD/$f'"; done) -c copy output.avi
Of course, adding "safe 0" means that safety-checks are now disabled. Use at your own risk! :?


Thanks to thread "FFMpeg concat demuxer unsafe file name" (superuser.com)
Post Reply