Recording webcam video - ffmpeg - error
You're saving to AVI which doesn't truly support variable frame rates so ffmpeg writes empty packets to emulate it. Apparently, the time base chosen is very fine and so ffmpeg has to write many skip packets (can't confirm since there's no log). 

For segments, you should save to .ts or .mp4 or .mkv