# HG changeset patch # User Jim Blandy # Date 681099875 0 # Node ID 481e29c1e27ea51f2b6a648d474c4af98f973762 # Parent 54ac13a6f74e059cbd3760b81ff69f745d34e549 *** empty log message *** diff -r 54ac13a6f74e -r 481e29c1e27e src/editfns.c --- a/src/editfns.c Fri Aug 02 00:39:31 1991 +0000 +++ b/src/editfns.c Fri Aug 02 02:24:35 1991 +0000 @@ -19,7 +19,13 @@ #include "config.h" + +#ifdef VMS +#include "pwd.h" +#else #include +#endif + #include "lisp.h" #include "buffer.h" #include "window.h" diff -r 54ac13a6f74e -r 481e29c1e27e src/emacs.c --- a/src/emacs.c Fri Aug 02 00:39:31 1991 +0000 +++ b/src/emacs.c Fri Aug 02 02:24:35 1991 +0000 @@ -379,8 +379,10 @@ signal (22, fatal_error_signal); signal (23, fatal_error_signal); signal (24, fatal_error_signal); +#ifdef SIGIO signal (SIGAIO, fatal_error_signal); signal (SIGPTY, fatal_error_signal); +#endif signal (SIGIOINT, fatal_error_signal); signal (SIGGRANT, fatal_error_signal); signal (SIGRETRACT, fatal_error_signal); diff -r 54ac13a6f74e -r 481e29c1e27e src/fileio.c --- a/src/fileio.c Fri Aug 02 00:39:31 1991 +0000 +++ b/src/fileio.c Fri Aug 02 02:24:35 1991 +0000 @@ -20,12 +20,27 @@ #include #include + +#ifdef VMS +#include "pwd.h" +#else #include +#endif + #include + +#ifdef VMS +#include "dir.h" +#include +#include +#include +#else #include +#endif + #include -#ifndef VMS +#ifndef vax11c extern int errno; extern char *sys_errlist[]; extern int sys_nerr; @@ -46,7 +61,6 @@ #include "window.h" #ifdef VMS -#include #include #include #include @@ -217,7 +231,8 @@ brack = ']'; strcpy (out, "[."); } - if (dot = index (p, '.')) + dot = index (p, '.'); + if (dot) { /* blindly remove any extension */ size = strlen (out) + (dot - p); @@ -348,7 +363,8 @@ /* If bracket is ']' or '>', bracket - 2 is the corresponding opening bracket. */ - if (!(ptr = index (src, bracket - 2))) + ptr = index (src, bracket - 2); + if (ptr == 0) { /* no opening bracket */ strcpy (dst, src); return 0; @@ -648,9 +664,24 @@ newdir = XSTRING (defalt)->data; } - /* Now concatenate the directory and name to new space in the stack frame */ + if (newdir != 0) + { + /* Get rid of any slash at the end of newdir. */ + int length = strlen (newdir); + if (newdir[length - 1] == '/') + { + unsigned char *temp = (unsigned char *) alloca (length); + bcopy (newdir, temp, length - 1); + temp[length - 1] = 0; + newdir = temp; + } + tlen = length + 1; + } + else + tlen = 0; - tlen = (newdir ? strlen (newdir) + 1 : 0) + strlen (nm) + 1; + /* Now concatenate the directory and name to new space in the stack frame */ + tlen += strlen (nm) + 1; target = (unsigned char *) alloca (tlen); *target = 0; diff -r 54ac13a6f74e -r 481e29c1e27e src/filelock.c --- a/src/filelock.c Fri Aug 02 00:39:31 1991 +0000 +++ b/src/filelock.c Fri Aug 02 02:24:35 1991 +0000 @@ -20,7 +20,13 @@ #include #include #include "config.h" + +#ifdef VMS +#include "pwd.h" +#else #include +#endif + #include #include #ifdef USG