1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2025-07-16 22:42:38 +02:00

lavf/ftp: fix possible crash

This commit is contained in:
Lukasz Marek
2013-08-29 01:54:04 +02:00
parent c4810fbe4f
commit f3ace37a3b

View File

@ -128,6 +128,7 @@ static int ftp_status(FTPContext *s, char **line, const int response_codes[])
while (!code_found || dash) { while (!code_found || dash) {
if ((err = ftp_get_line(s, buf, sizeof(buf))) < 0) { if ((err = ftp_get_line(s, buf, sizeof(buf))) < 0) {
if (line)
av_bprint_finalize(&line_buffer, NULL); av_bprint_finalize(&line_buffer, NULL);
return err; return err;
} }