]> TLD Linux GIT Repositories - packages/mysql.git/blobdiff - mysql-readline.patch
- updated to 8.4.4, use %patch -P
[packages/mysql.git] / mysql-readline.patch
index ed12c3af0b259050642af4bf2a127b54cd1409f1..bb26141dcd46b7cd2a8e34535a67ded86e7b9a08 100644 (file)
@@ -1,21 +1,34 @@
---- Percona-Server-5.6.15-rel63.0/client/mysql.cc.orig 2014-02-09 06:23:16.085128298 +0100
-+++ Percona-Server-5.6.15-rel63.0/client/mysql.cc      2014-02-09 06:38:54.561791068 +0100
-@@ -103,7 +103,9 @@
- #include <conio.h>
+diff -urNpa mysql-8.4.4.orig/client/mysql.cc mysql-8.4.4/client/mysql.cc
+--- mysql-8.4.4.orig/client/mysql.cc   2025-02-20 23:13:30.590476312 +0100
++++ mysql-8.4.4/client/mysql.cc        2025-02-20 23:15:26.195920130 +0100
+@@ -93,6 +93,7 @@ Foundation, Inc., 51 Franklin St, Fifth
+ #define LOG_USER 0
  #else
  #include <readline.h>
 +#include <history.h>
+ #include <syslog.h>
  #define HAVE_READLINE
-+#define USE_NEW_READLINE_INTERFACE
- #define USE_POPEN
- #endif
-   //int vidattr(long unsigned int attrs);     // Was missing in sun curses
-@@ -1107,7 +1109,7 @@
- } HIST_ENTRY; 
- #endif
+@@ -1186,22 +1187,6 @@ static COMMANDS commands[] = {
+ static const char *load_default_groups[] = {"mysql", "client", nullptr};
  
+ #ifdef HAVE_READLINE
+-/*
+- HIST_ENTRY is defined for libedit, but not for the real readline
+- Need to redefine it for real readline to find it
+-*/
+-#if !defined(HAVE_HIST_ENTRY)
+-typedef struct _hist_entry {
+-  const char *line;
+-  const char *data;
+-} HIST_ENTRY;
+-#endif
+-
 -extern "C" int add_history(const char *command); /* From readline directory */
-+extern "C" void add_history(const char *command); /* From readline directory */
- extern "C" int read_history(const char *command);
- extern "C" int write_history(const char *command);
- extern "C" HIST_ENTRY *history_get(int num);
+-extern "C" int read_history(const char *command);
+-extern "C" int write_history(const char *command);
+-extern "C" HIST_ENTRY *history_get(int num);
+-extern "C" int history_length;
+ static int not_in_history(const char *line);
+ static void initialize_readline(char *name);
+ #endif /* HAVE_READLINE */