vlc | branch: master | Rémi Denis-Courmont <[email protected]> | Sat Nov 23 18:25:04 2019 +0200| [5f6dbc140ff56180edc5b215905baf0b5bad524f] | committer: Rémi Denis-Courmont
xcb/screen: fix build without <sys/shm.h> > http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=5f6dbc140ff56180edc5b215905baf0b5bad524f --- modules/access/screen/xcb.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/modules/access/screen/xcb.c b/modules/access/screen/xcb.c index df7bd2e1b6..1268dae577 100644 --- a/modules/access/screen/xcb.c +++ b/modules/access/screen/xcb.c @@ -109,7 +109,9 @@ typedef struct float rate; /**< Frame rate */ xcb_window_t window; /**< Captured window XID */ xcb_pixmap_t pixmap; /**< Pixmap for composited capture */ +#ifdef HAVE_SYS_SHM_H xcb_shm_seg_t segment; /**< SHM segment XID */ +#endif int16_t x, y; /**< Requested capture top-left coordinates */ uint16_t w, h; /**< Requested capture pixel dimensions */ uint8_t bpp; /**< Actual bytes per pixel *es */ @@ -218,7 +220,9 @@ static int Open (vlc_object_t *obj) /* Window properties */ p_sys->pixmap = xcb_generate_id (conn); +#ifdef HAVE_SYS_SHM_H p_sys->segment = xcb_generate_id (conn); +#endif p_sys->shm = CheckSHM (conn); p_sys->w = var_InheritInteger (obj, "screen-width"); p_sys->h = var_InheritInteger (obj, "screen-height"); @@ -433,7 +437,7 @@ discard: free (geo); block_t *block = NULL; -#if HAVE_SYS_SHM_H +#ifdef HAVE_SYS_SHM_H if (sys->shm) { /* Capture screen through shared memory */ size_t size = w * h * sys->bpp; _______________________________________________ vlc-commits mailing list [email protected] https://mailman.videolan.org/listinfo/vlc-commits
