aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDan Nicolaescu2008-08-01 12:56:49 +0000
committerDan Nicolaescu2008-08-01 12:56:49 +0000
commit27ec92c98304e2b61dc20a1db65972b0eb00d4cc (patch)
tree1d472d88df9706bdaf6cd4393cc5a054b7db6b77 /src
parentdfc7a783d993dc5e4007085f06dc2eb406887f0d (diff)
downloademacs-27ec92c98304e2b61dc20a1db65972b0eb00d4cc.tar.gz
emacs-27ec92c98304e2b61dc20a1db65972b0eb00d4cc.zip
Fix previous change that removed BSD_TERMIOS. Add
comments to #ifdefs.
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog5
-rw-r--r--src/systty.h27
2 files changed, 22 insertions, 10 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 9c4f4676940..1bf57826ca2 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,8 @@
12008-08-01 Dan Nicolaescu <dann@ics.uci.edu>
2
3 * systty.h: Fix previous change that removed BSD_TERMIOS. Add
4 comments to #ifdefs.
5
12008-08-01 Adrian Robert <Adrian.B.Robert@gmail.com> 62008-08-01 Adrian Robert <Adrian.B.Robert@gmail.com>
2 7
3 * w32fns.c (w32-load-color-file): Remove. 8 * w32fns.c (w32-load-color-file): Remove.
diff --git a/src/systty.h b/src/systty.h
index b846a026232..b057b479060 100644
--- a/src/systty.h
+++ b/src/systty.h
@@ -151,12 +151,19 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
151 151
152#ifdef EMACS_HAVE_TTY_PGRP 152#ifdef EMACS_HAVE_TTY_PGRP
153 153
154#if defined (HAVE_TERMIOS)
155
156#define EMACS_GET_TTY_PGRP(fd, pgid) (*(pgid) = tcgetpgrp ((fd)))
157#define EMACS_SET_TTY_PGRP(fd, pgid) (tcsetpgrp ((fd), *(pgid)))
158
159#else /* not HAVE_TERMIOS */
154#ifdef TIOCSPGRP 160#ifdef TIOCSPGRP
155 161
156#define EMACS_GET_TTY_PGRP(fd, pgid) (ioctl ((fd), TIOCGPGRP, (pgid))) 162#define EMACS_GET_TTY_PGRP(fd, pgid) (ioctl ((fd), TIOCGPGRP, (pgid)))
157#define EMACS_SET_TTY_PGRP(fd, pgid) (ioctl ((fd), TIOCSPGRP, (pgid))) 163#define EMACS_SET_TTY_PGRP(fd, pgid) (ioctl ((fd), TIOCSPGRP, (pgid)))
158 164
159#endif /* TIOCSPGRP */ 165#endif /* TIOCSPGRP */
166#endif /* HAVE_TERMIOS */
160 167
161#else /* not EMACS_SET_TTY_PGRP */ 168#else /* not EMACS_SET_TTY_PGRP */
162 169
@@ -170,7 +177,7 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
170 177
171#if defined (GETPGRP_VOID) 178#if defined (GETPGRP_VOID)
172# define EMACS_GETPGRP(x) getpgrp() 179# define EMACS_GETPGRP(x) getpgrp()
173#else 180#else /* !GETPGRP_VOID */
174# define EMACS_GETPGRP(x) getpgrp(x) 181# define EMACS_GETPGRP(x) getpgrp(x)
175#endif /* !GETPGRP_VOID */ 182#endif /* !GETPGRP_VOID */
176 183
@@ -209,30 +216,30 @@ struct emacs_tty {
209 for dummy get and set definitions. */ 216 for dummy get and set definitions. */
210#ifdef HAVE_TCATTR 217#ifdef HAVE_TCATTR
211 struct termios main; 218 struct termios main;
212#else 219#else /* not HAVE_TCATTR */
213#ifdef HAVE_TERMIO 220#ifdef HAVE_TERMIO
214 struct termio main; 221 struct termio main;
215#else 222#else /* not HAVE_TERMIO */
216#ifdef DOS_NT 223#ifdef DOS_NT
217 int main; 224 int main;
218#else /* not DOS_NT */ 225#else /* not DOS_NT */
219 struct sgttyb main; 226 struct sgttyb main;
220#endif /* not DOS_NT */ 227#endif /* not DOS_NT */
221#endif 228#endif /* not HAVE_TERMIO */
222#endif 229#endif /* not HAVE_TCATTR */
223 230
224/* If we have TERMIOS, we don't need to do this - they're taken care of 231/* If we have TERMIOS, we don't need to do this - they're taken care of
225 by the tc*attr calls. */ 232 by the tc*attr calls. */
226#ifndef HAVE_TERMIOS 233#ifndef HAVE_TERMIOS
227#ifdef HAVE_LTCHARS 234#ifdef HAVE_LTCHARS
228 struct ltchars ltchars; 235 struct ltchars ltchars;
229#endif 236#endif /* HAVE_LTCHARS */
230 237
231#ifdef HAVE_TCHARS 238#ifdef HAVE_TCHARS
232 struct tchars tchars; 239 struct tchars tchars;
233 int lmode; 240 int lmode;
234#endif 241#endif /* HAVE_TCHARS */
235#endif 242#endif /* not defined HAVE_TERMIOS */
236}; 243};
237 244
238/* Define EMACS_GET_TTY and EMACS_SET_TTY, 245/* Define EMACS_GET_TTY and EMACS_SET_TTY,
@@ -255,9 +262,9 @@ extern int emacs_set_tty P_ ((int, struct emacs_tty *, int));
255 262
256#ifdef TABDLY 263#ifdef TABDLY
257#define EMACS_TTY_TABS_OK(p) (((p)->main.c_oflag & TABDLY) != TAB3) 264#define EMACS_TTY_TABS_OK(p) (((p)->main.c_oflag & TABDLY) != TAB3)
258#else 265#else /* not TABDLY */
259#define EMACS_TTY_TABS_OK(p) 1 266#define EMACS_TTY_TABS_OK(p) 1
260#endif 267#endif /* not TABDLY */
261 268
262#else /* not def HAVE_TERMIOS */ 269#else /* not def HAVE_TERMIOS */
263#ifdef HAVE_TERMIO 270#ifdef HAVE_TERMIO