From 5400811b83ea38ce2b746867014e048bc2a8a922 Mon Sep 17 00:00:00 2001 From: ManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com> Date: Wed, 13 Mar 2024 15:23:43 +0100 Subject: Update libdecor to upstream commit 4f2c03d5 - cont'd --- documentation/src/bundled-libs.dox | 4 ++-- documentation/src/wayland.dox | 2 +- src/drivers/Wayland/Fl_Wayland_Graphics_Driver.cxx | 6 +++--- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/documentation/src/bundled-libs.dox b/documentation/src/bundled-libs.dox index 331c8a278..1cdaeae2a 100644 --- a/documentation/src/bundled-libs.dox +++ b/documentation/src/bundled-libs.dox @@ -23,14 +23,14 @@ The nanosvg library is not affected. \section bundled-status Current status \code -Current versions of bundled libraries (as of March 12, 2024): +Current versions of bundled libraries (as of March 13, 2024): Library Version/git commit Release date FLTK Version -------------------------------------------------------------------------- jpeg jpeg-9f 2024-01-14 1.4.0 nanosvg 7aeda550a8 [1] 2023-12-02 1.4.0 png libpng-1.6.42 2024-01-29 1.4.0 zlib zlib-1.3.1 2024-01-22 1.4.0 - libdecor 09875530 [2] 2024-03-03 1.4.0 + libdecor 4f2c03d5 [2] 2024-03-04 1.4.0 -------------------------------------------------------------------------- Previous versions of bundled libraries (FLTK 1.3.x): diff --git a/documentation/src/wayland.dox b/documentation/src/wayland.dox index 56f47c208..88f4d4dbf 100644 --- a/documentation/src/wayland.dox +++ b/documentation/src/wayland.dox @@ -694,7 +694,7 @@ FLTK creates a \c wl_buffer object each time an Fl_Window is mapped on a display That's done by member function \c Fl_Wayland_Graphics_Driver::create_shm_buffer() which follows this 3-step procedure to create a "buffer factory" for FLTK and to construct Wayland buffers from it: -- Libdecor function os_create_anonymous_file(off_t size) creates an adequate file +- Libdecor function libdecor_os_create_anonymous_file(off_t size) creates an adequate file and mmap's it. This file lives in RAM because it is created by function \c memfd_create(). FLTK sets this file size to 10 MB unless the size of the buffer to be created is larger; in that case the anonymous file is sized to twice the buffer size. diff --git a/src/drivers/Wayland/Fl_Wayland_Graphics_Driver.cxx b/src/drivers/Wayland/Fl_Wayland_Graphics_Driver.cxx index 2dd6ac527..ce9dcaf4e 100644 --- a/src/drivers/Wayland/Fl_Wayland_Graphics_Driver.cxx +++ b/src/drivers/Wayland/Fl_Wayland_Graphics_Driver.cxx @@ -25,7 +25,7 @@ extern "C" { -# include "../../../libdecor/src/os-compatibility.h" // for os_create_anonymous_file() +# include "../../../libdecor/src/os-compatibility.h" // for libdecor_os_create_anonymous_file() } // used by create_shm_buffer and do_buffer_release @@ -76,9 +76,9 @@ void Fl_Wayland_Graphics_Driver::create_shm_buffer(Fl_Wayland_Graphics_Driver::w pool_size = default_pool_size; if (buffer->draw_buffer.data_size > pool_size) pool_size = 2 * buffer->draw_buffer.data_size; // a larger pool is needed - int fd = os_create_anonymous_file(pool_size); + int fd = libdecor_os_create_anonymous_file(pool_size); if (fd < 0) { - Fl::fatal("os_create_anonymous_file failed: %s\n", strerror(errno)); + Fl::fatal("libdecor_os_create_anonymous_file failed: %s\n", strerror(errno)); } pool_data = (struct wld_shm_pool_data*)calloc(1, sizeof(struct wld_shm_pool_data)); pool_data->pool_memory = (char*)mmap(NULL, pool_size, PROT_READ | PROT_WRITE, -- cgit v1.2.3