This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [RFC/AIX] xm-aix4.h - Move some host-specific stuff


   Date: Sat, 7 Aug 2004 22:14:20 -0700
   From: Joel Brobecker <brobecker@gnat.com>

   The last part of config/xm-aix4.h contains the following definitions:

   | /* Signal handler for SIGWINCH `window size changed'. */
   | 
   | #define SIGWINCH_HANDLER  aix_resizewindow
   | extern void aix_resizewindow (int);
   | 
   | /* `lines_per_page' and `chars_per_line' are local to utils.c. Rectify this. */
   | #define SIGWINCH_HANDLER_BODY   \
   |                                                                         \
   | /* Respond to SIGWINCH `window size changed' signal, and reset GDB's    \
   |    window settings appropriately. */                                    \
   |                                                                         \
   | void                                            \
   | aix_resizewindow (signo)                        \
   |      int signo;                                 \
   | {                                               \
   |   int fd = fileno (stdout);                     \
   |   if (isatty (fd)) {                            \
   |     int val;                                    \
   |                                                 \
   |     val = atoi (termdef (fd, 'l'));             \
   |     if (val > 0)                                \
   |       lines_per_page = val;                     \
   |     val = atoi (termdef (fd, 'c'));             \
   |     if (val > 0)                                \
   |       chars_per_line = val;                     \
   |   }                                             \
   | }

Nowadays, GDB relies very much on readline to get this right.  If
readline gets this right on AIX, this bit can simply go.  I'm failrly
certain readline gets this right on AIX, since readline seems to do
exectly what the AIX Technical Reference says that termdef does.

Mark


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]