ffmpeg.c:3685: error: Null Dereference
  pointer `p` last assigned on line 3685 could be null and is dereferenced at line 3685, column 5.

ffmpeg.c:3670:1: start of procedure opt_streamid()
3668. 
3669. /* arg format is "output-stream-index:streamid-value". */
3670. static void opt_streamid(const char *opt, const char *arg)
      ^
3671. {
3672.     int idx;

ffmpeg.c:3676:5: 
3674.     char idx_str[16];
3675. 
3676.     strncpy(idx_str, arg, sizeof(idx_str));
          ^
3677.     idx_str[sizeof(idx_str)-1] = '\0';
3678.     p = strchr(idx_str, ':');

ffmpeg.c:3677:5: 
3675. 
3676.     strncpy(idx_str, arg, sizeof(idx_str));
3677.     idx_str[sizeof(idx_str)-1] = '\0';
          ^
3678.     p = strchr(idx_str, ':');
3679.     if (!p) {

ffmpeg.c:3678:5: 
3676.     strncpy(idx_str, arg, sizeof(idx_str));
3677.     idx_str[sizeof(idx_str)-1] = '\0';
3678.     p = strchr(idx_str, ':');
          ^
3679.     if (!p) {
3680.         fprintf(stderr,

ffmpeg.c:3679:10: Taking true branch
3677.     idx_str[sizeof(idx_str)-1] = '\0';
3678.     p = strchr(idx_str, ':');
3679.     if (!p) {
               ^
3680.         fprintf(stderr,
3681.                 "Invalid value '%s' for option '%s', required syntax is 'index:value'\n",

ffmpeg.c:3680:9: 
3678.     p = strchr(idx_str, ':');
3679.     if (!p) {
3680.         fprintf(stderr,
              ^
3681.                 "Invalid value '%s' for option '%s', required syntax is 'index:value'\n",
3682.                 arg, opt);

ffmpeg.c:3683:9: Skipping ffmpeg_exit(): empty list of specs
3681.                 "Invalid value '%s' for option '%s', required syntax is 'index:value'\n",
3682.                 arg, opt);
3683.         ffmpeg_exit(1);
              ^
3684.     }
3685.     *p++ = '\0';

ffmpeg.c:3685:5: 
3683.         ffmpeg_exit(1);
3684.     }
3685.     *p++ = '\0';
          ^
3686.     idx = parse_number_or_die(opt, idx_str, OPT_INT, 0, MAX_STREAMS-1);
3687.     streamid_map = grow_array(streamid_map, sizeof(*streamid_map), &nb_streamid_map, idx+1);
