patch 9.2.0514: GTK4: build errors when socketserver is enabled

Commit: 
https://github.com/vim/vim/commit/ea71d5bb01ead1f982148771799462e91136107f
Author: Foxe Chen <[email protected]>
Date:   Fri May 22 22:18:03 2026 +0000

    patch 9.2.0514: GTK4: build errors when socketserver is enabled
    
    Problem:  GTK4: build errors when socketserver is enabled
              (after v9.2.0512)
    Solution: Drop unused functions (Foxe Chen)
    
    closes: #20293
    
    Signed-off-by: Foxe Chen <[email protected]>
    Signed-off-by: Christian Brabandt <[email protected]>

diff --git a/src/gui_gtk4.c b/src/gui_gtk4.c
index 083ac9f40..508a33d58 100644
--- a/src/gui_gtk4.c
+++ b/src/gui_gtk4.c
@@ -112,13 +112,6 @@ vim_parse_geometry(const char *str, int *x, int *y,
     return mask;
 }
 
-#ifdef FEAT_SOCKETSERVER
-# include <glib-unix.h>
-
-// Used to track the source for the listening socket
-static guint socket_server_source_id = 0;
-#endif
-
 #if defined(FEAT_MOUSESHAPE)
 // Last set mouse pointer shape
 static int last_shape = 0;
@@ -2991,59 +2984,6 @@ gui_get_x11_windis(Window *win UNUSED, Display **dis 
UNUSED)
     return FAIL;
 }
 
-#if defined(FEAT_SOCKETSERVER)
-
-/*
- * Callback for new events from the socket server listening socket.
- */
-    static int
-socket_server_poll_in(int fd UNUSED, GIOCondition cond,
-                     void *user_data UNUSED)
-{
-    if (cond & G_IO_IN)
-       socket_server_accept_client();
-    else if (cond & (G_IO_ERR | G_IO_HUP))
-    {
-       socket_server_uninit();
-       return FALSE;
-    }
-
-    return TRUE;
-}
-
-#endif // FEAT_SOCKETSERVER
-
-/*
- * Initialize socket server for use in the GUI (does not actually initialize
- * the socket server, only attaches a source).
- */
-    void
-gui_gtk_init_socket_server(void)
-{
-#if defined(FEAT_SOCKETSERVER)
-    if (socket_server_source_id > 0)
-       return;
-    // Register source for file descriptor to global default context
-    socket_server_source_id = g_unix_fd_add(socket_server_get_fd(),
-           G_IO_IN | G_IO_ERR | G_IO_HUP, socket_server_poll_in, NULL);
-#endif
-}
-
-/*
- * Remove the source for the socket server listening socket.
- */
-    void
-gui_gtk_uninit_socket_server(void)
-{
-#if defined(FEAT_SOCKETSERVER)
-    if (socket_server_source_id > 0)
-    {
-       g_source_remove(socket_server_source_id);
-       socket_server_source_id = 0;
-    }
-#endif
-}
-
     void
 gui_gtk_set_mnemonics(int enable UNUSED)
 {
diff --git a/src/proto/gui_gtk4.pro b/src/proto/gui_gtk4.pro
index 1f13ab6ca..7359c750c 100644
--- a/src/proto/gui_gtk4.pro
+++ b/src/proto/gui_gtk4.pro
@@ -70,8 +70,6 @@ void gui_mch_destroy_sign(void *sign);
 int gui_gtk_draw_string_ext(int row, int col, char_u *s, int len, int flags, 
int force_pango);
 int gui_gtk_draw_string(int row, int col, char_u *s, int len, int flags);
 int gui_get_x11_windis(Window *win, Display **dis);
-void gui_gtk_init_socket_server(void);
-void gui_gtk_uninit_socket_server(void);
 void gui_gtk_set_mnemonics(int enable);
 void gui_make_popup(char_u *path_name, int mouse_pos);
 int get_menu_tool_width(void);
diff --git a/src/version.c b/src/version.c
index f0e32a02a..a2674417d 100644
--- a/src/version.c
+++ b/src/version.c
@@ -729,6 +729,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    514,
 /**/
     513,
 /**/

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion visit 
https://groups.google.com/d/msgid/vim_dev/E1wQYNX-001G12-VN%40256bit.org.

Raspunde prin e-mail lui