mirror of
https://git.videolan.org/git/ffmpeg.git
synced 2024-09-12 18:25:57 +02:00
Merge commit '2c3f29c4894ee50635b846f202296ad79a7c0d33'
* commit '2c3f29c4894ee50635b846f202296ad79a7c0d33':
xcbgrab: Support empty filename string correctly
Conflicts:
libavdevice/xcbgrab.c
See: 62eca2f827
Merged-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
commit
81a045fe17
@ -613,11 +613,11 @@ static av_cold int xcbgrab_read_header(AVFormatContext *s)
|
||||
sscanf(s->filename, "+%d,%d", &c->x, &c->y);
|
||||
}
|
||||
|
||||
c->conn = xcb_connect(display_name, &screen_num);
|
||||
c->conn = xcb_connect(display_name[0] ? display_name : NULL, &screen_num);
|
||||
av_freep(&display_name);
|
||||
if ((ret = xcb_connection_has_error(c->conn))) {
|
||||
av_log(s, AV_LOG_ERROR, "Cannot open display %s, error %d.\n",
|
||||
(*s->filename) ? s->filename : "default", ret);
|
||||
s->filename[0] ? s->filename : "default", ret);
|
||||
return AVERROR(EIO);
|
||||
}
|
||||
setup = xcb_get_setup(c->conn);
|
||||
|
Loading…
Reference in New Issue
Block a user