Update video_reader.c

Add len function to count size of string, and changed algorithm to key[i%len(key)]