libavformat/movenc.c:1378: error: Integer Overflow L2
  ([1, 32] - [0, 31]):unsigned64 by call to `av_get_codec_tag_string`.

libavformat/movenc.c:1378:13: Call
1376.         } else {
1377.             char tag_buf[32];
1378.             av_get_codec_tag_string(tag_buf, sizeof(tag_buf),
                  ^
1379.                                     track->par->codec_tag);
1380. 

libavcodec/utils.c:1751:1: <LHS trace>
1749. }
1750. 
1751. size_t av_get_codec_tag_string(char *buf, size_t buf_size, unsigned int codec_tag)
      ^
1752. {
1753.     int i, len, ret = 0;

libavcodec/utils.c:1751:1: Parameter `buf_size`
  1749. }
  1750. 
  1751. size_t av_get_codec_tag_string(char *buf, size_t buf_size, unsigned int codec_tag)
        ^
  1752. {
  1753.     int i, len, ret = 0;

libavcodec/utils.c:1751:1: <RHS trace>
1749. }
1750. 
1751. size_t av_get_codec_tag_string(char *buf, size_t buf_size, unsigned int codec_tag)
      ^
1752. {
1753.     int i, len, ret = 0;

libavcodec/utils.c:1751:1: Parameter `buf_size`
  1749. }
  1750. 
  1751. size_t av_get_codec_tag_string(char *buf, size_t buf_size, unsigned int codec_tag)
        ^
  1752. {
  1753.     int i, len, ret = 0;

libavcodec/utils.c:1764:23: Binary operation: ([1, 32] - [0, 31]):unsigned64 by call to `av_get_codec_tag_string` 
  1762.                        TAG_PRINT(codec_tag & 0xFF) ? "%c" : "[%d]", codec_tag & 0xFF);
  1763.         buf        += len;
  1764.         buf_size    = buf_size > len ? buf_size - len : 0;
                              ^
  1765.         ret        += len;
  1766.         codec_tag >>= 8;

size_t av_get_codec_tag_string(char *buf, size_t buf_size, unsigned int codec_tag)
{
    int i, len, ret = 0;
#define TAG_PRINT(x)                                              \
    (((x) >= '0' && (x) <= '9') ||                                \
     ((x) >= 'a' && (x) <= 'z') || ((x) >= 'A' && (x) <= 'Z') ||  \
     ((x) == '.' || (x) == ' '))
    for (i = 0; i < 4; i++) {
        len = snprintf(buf, buf_size,
                       TAG_PRINT(codec_tag & 0xFF) ? "%c" : "[%d]", codec_tag & 0xFF);
        buf        += len;
        buf_size    = buf_size > len ? buf_size - len : 0;
        ret        += len;
        codec_tag >>= 8;
    }
    return ret;
}
['static int mov_write_hdlr_tag(AVFormatContext *s, AVIOContext *pb, MOVTrack *track)\n{\n    const char *hdlr, *descr = NULL, *hdlr_type = NULL;\n    int64_t pos = avio_tell(pb);\n    hdlr      = "dhlr";\n    hdlr_type = "url ";\n    descr     = "DataHandler";\n    if (track) {\n        hdlr = (track->mode == MODE_MOV) ? "mhlr" : "\\0\\0\\0\\0";\n        if (track->par->codec_type == AVMEDIA_TYPE_VIDEO) {\n            hdlr_type = "vide";\n            descr     = "VideoHandler";\n        } else if (track->par->codec_type == AVMEDIA_TYPE_AUDIO) {\n            hdlr_type = "soun";\n            descr     = "SoundHandler";\n        } else if (track->par->codec_type == AVMEDIA_TYPE_SUBTITLE) {\n            if (track->tag == MKTAG(\'t\',\'x\',\'3\',\'g\')) {\n                hdlr_type = "sbtl";\n            } else if (track->tag == MKTAG(\'m\',\'p\',\'4\',\'s\')) {\n                hdlr_type = "subp";\n            } else if (is_clcp_track(track)) {\n                hdlr_type = "clcp";\n            } else {\n                hdlr_type = "text";\n            }\n            descr = "SubtitleHandler";\n        } else if (track->par->codec_tag == MKTAG(\'r\',\'t\',\'p\',\' \')) {\n            hdlr_type = "hint";\n            descr     = "HintHandler";\n        } else if (track->par->codec_tag == MKTAG(\'t\',\'m\',\'c\',\'d\')) {\n            hdlr_type = "tmcd";\n            descr = "TimeCodeHandler";\n        } else {\n            char tag_buf[32];\n            av_get_codec_tag_string(tag_buf, sizeof(tag_buf),\n                                    track->par->codec_tag);\n            av_log(s, AV_LOG_WARNING,\n                   "Unknown hldr_type for %s / 0x%04X, writing dummy values\\n",\n                   tag_buf, track->par->codec_tag);\n        }\n        if (track->st) {\n            AVDictionaryEntry *t;\n            t = av_dict_get(track->st->metadata, "handler", NULL, 0);\n            if (t && utf8len(t->value))\n                descr = t->value;\n        }\n    }\n    avio_wb32(pb, 0);\n    ffio_wfourcc(pb, "hdlr");\n    avio_wb32(pb, 0);\n    avio_write(pb, hdlr, 4);\n    ffio_wfourcc(pb, hdlr_type);\n    avio_wb32(pb, 0);\n    avio_wb32(pb, 0);\n    avio_wb32(pb, 0);\n    if (!track || track->mode == MODE_MOV)\n        avio_w8(pb, strlen(descr));\n    avio_write(pb, descr, strlen(descr));\n    if (track && track->mode != MODE_MOV)\n        avio_w8(pb, 0);\n    return update_size(pb, pos);\n}', 'size_t av_get_codec_tag_string(char *buf, size_t buf_size, unsigned int codec_tag)\n{\n    int i, len, ret = 0;\n#define TAG_PRINT(x)                                              \\\n    (((x) >= \'0\' && (x) <= \'9\') ||                                \\\n     ((x) >= \'a\' && (x) <= \'z\') || ((x) >= \'A\' && (x) <= \'Z\') ||  \\\n     ((x) == \'.\' || (x) == \' \'))\n    for (i = 0; i < 4; i++) {\n        len = snprintf(buf, buf_size,\n                       TAG_PRINT(codec_tag & 0xFF) ? "%c" : "[%d]", codec_tag & 0xFF);\n        buf        += len;\n        buf_size    = buf_size > len ? buf_size - len : 0;\n        ret        += len;\n        codec_tag >>= 8;\n    }\n    return ret;\n}']