X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=httpd.cpp;h=3eda2a1e34b5d9fc7e62479d6a53ffe9612e3679;hb=90499af3e3372016f8c34e1f2facdefa0277bf4a;hp=29923f9430413ee5dec3175e0aaae42a7f257cf1;hpb=0fff2c95c89541e5b23611962a00886c64c00daa;p=nageru diff --git a/httpd.cpp b/httpd.cpp index 29923f9..3eda2a1 100644 --- a/httpd.cpp +++ b/httpd.cpp @@ -51,6 +51,7 @@ void HTTPD::open_output_file(const string &filename) { AVFormatContext *avctx = avformat_alloc_context(); avctx->oformat = av_guess_format(NULL, filename.c_str(), NULL); + assert(filename.size() < sizeof(avctx->filename) - 1); strcpy(avctx->filename, filename.c_str()); string url = "file:" + filename;