updates for several readline examples; update examples in readline documentation; update documentation for --rcfile option

This commit is contained in:
Chet Ramey
2024-07-02 14:34:40 -04:00
parent 5e28a1813c
commit dbff8b786e
10 changed files with 100 additions and 102 deletions
+7 -2
View File
@@ -23,12 +23,15 @@
# include <readline/history.h>
#endif
#if !defined (errno)
extern int errno;
#endif
static void cb_linehandler (char *);
static void signandler (int);
int running, sigwinch_received;
int running;
int sigwinch_received;
const char *prompt = "rltest$ ";
/* Handle SIGWINCH and window size changes when readline is not active and
@@ -73,9 +76,11 @@ main (int c, char **v)
fd_set fds;
int r;
/* Set the default locale values according to environment variables. */
setlocale (LC_ALL, "");
/* Handle SIGWINCH */
/* Handle window size changes when readline is not active and reading
characters. */
signal (SIGWINCH, sighandler);
/* Install the line handler. */