File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed
Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -394,7 +394,13 @@ uint32_t x_create_region(xcb_connection_t *c, const region_t *reg) {
394394 }
395395
396396 int nrects ;
397- auto rects = pixman_region32_rectangles (reg , & nrects );
397+ #pragma GCC diagnostic push
398+ // In older pixman versions, pixman_region32_rectangles doesn't take const region_t,
399+ // instead of dealing with this version difference, just suppress the warning.
400+ #pragma GCC diagnostic ignored "-Wdiscarded-qualifiers"
401+ #pragma GCC diagnostic ignored "-Wincompatible-pointer-types-discards-qualifiers"
402+ const pixman_box32_t * rects = pixman_region32_rectangles (reg , & nrects );
403+ #pragma GCC diagnostic pop
398404 auto xrects = ccalloc (nrects , xcb_rectangle_t );
399405 for (int i = 0 ; i < nrects ; i ++ ) {
400406 xrects [i ] =
You can’t perform that action at this time.
0 commit comments