Mercurial > hg > xemacs-beta
changeset 5337:906ccc7dcd70
Change to qxesprintf(), qxestrcpy(), s/hpux11.h, s/usg5-4.h
2011-01-14 Aidan Kehoe <kehoea@parhasard.net>
* s/hpux11.h (PTY_TTY_NAME_SPRINTF, PTY_NAME_SPRINTF):
* s/usg5-4.h (PTY_TTY_NAME_SPRINTF, PTY_NAME_SPRINTF):
Replace sprintf() with qxesprintf(), strcpy with qxestrpy(),
hopefully fixing some platform-specific C++ builds.
author | Aidan Kehoe <kehoea@parhasard.net> |
---|---|
date | Fri, 14 Jan 2011 23:23:30 +0000 |
parents | 287499ff4c5f |
children | 8608eadee6ba |
files | src/ChangeLog src/s/hpux11.h src/s/usg5-4.h |
diffstat | 3 files changed, 11 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/src/ChangeLog Fri Jan 14 23:16:25 2011 +0000 +++ b/src/ChangeLog Fri Jan 14 23:23:30 2011 +0000 @@ -1,3 +1,10 @@ +2011-01-14 Aidan Kehoe <kehoea@parhasard.net> + + * s/hpux11.h (PTY_TTY_NAME_SPRINTF, PTY_NAME_SPRINTF): + * s/usg5-4.h (PTY_TTY_NAME_SPRINTF, PTY_NAME_SPRINTF): + Replace sprintf() with qxesprintf(), strcpy with qxestrpy(), + hopefully fixing some platform-specific C++ builds. + 2011-01-14 Aidan Kehoe <kehoea@parhasard.net> * fns.c (Ffind): Use the correct subr information here, pass in
--- a/src/s/hpux11.h Fri Jan 14 23:16:25 2011 +0000 +++ b/src/s/hpux11.h Fri Jan 14 23:23:30 2011 +0000 @@ -104,11 +104,11 @@ /* This is how to get the device name of the tty end of a pty. */ #define PTY_TTY_NAME_SPRINTF \ - sprintf (pty_name, "/dev/pty/tty%c%x", c, i); + qxesprintf (pty_name, "/dev/pty/tty%c%x", c, i); /* This is how to get the device name of the control end of a pty. */ #define PTY_NAME_SPRINTF \ - sprintf (pty_name, "/dev/ptym/pty%c%x", c, i); + qxesprintf (pty_name, "/dev/ptym/pty%c%x", c, i); #ifdef HPUX_USE_SHLIBS #define LD_SWITCH_SYSTEM
--- a/src/s/usg5-4.h Fri Jan 14 23:16:25 2011 +0000 +++ b/src/s/usg5-4.h Fri Jan 14 23:23:30 2011 +0000 @@ -124,7 +124,7 @@ /* This sets the name of the master side of the PTY. */ -#define PTY_NAME_SPRINTF strcpy (pty_name, "/dev/ptmx"); +#define PTY_NAME_SPRINTF qxestrcpy (pty_name, "/dev/ptmx"); /* This sets the name of the slave side of the PTY. On SysVr4, grantpt(3) forks a subprocess, so keep sigchld_handler() from @@ -150,7 +150,7 @@ { close (fd); return -1; } \ if (!(ptyname = ptsname (fd))) \ { close (fd); return -1; } \ - strncpy (pty_name, ptyname, sizeof (pty_name)); \ + qxestrncpy (pty_name, ptyname, sizeof (pty_name)); \ pty_name[sizeof (pty_name) - 1] = 0; \ }