Article View: gnu.emacs.bug
Article #1222filelock.c - No fchmod() on System V systems
From: Kayvan Sylvan
Date: Thu, 01 Dec 1988 23:43
Date: Thu, 01 Dec 1988 23:43
34 lines
1270 bytes
1270 bytes
In GNU Emacs 18.52.5 of Thu Dec 1 1988 on satyr (usg-unix-v)
In filelock.c, fchmod is used in two places. If CLASH_DETECTION is
turned on for Unix SysV systems, temacs will not be loaded.
Here's a simple fix for this problem:
*** filelock.c~ Thu Dec 1 15:24:45 1988
--- filelock.c Thu Dec 1 15:24:45 1988
***************
*** 149,153 ****
--- 149,157 ----
if ((fd = open (lfname, mode, 0666)) >= 0)
{
+ #ifdef USG
+ chmod (lfname, 0666);
+ #else
fchmod (fd, 0666);
+ #endif
sprintf (buf, "%d ", getpid ());
write (fd, buf, strlen (buf));
***************
*** 252,256 ****
--- 256,264 ----
if (fd >= 0)
{
+ #ifdef USG
+ chmod (PATH_SUPERLOCK, 0666);
+ #else
fchmod (fd, 0666);
+ #endif
write (fd, lfname, strlen (lfname));
close (fd);
Technical Details
Message-ID:
<8812011543.AA05277@satyr.UUCP>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!watmath!uunet!tut.cis.ohio-state.edu!APPLE.COM!satyr!kayvanShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!watmath!uunet!tut.cis.ohio-state.edu!APPLE.COM!satyr!kayvan From: satyr!kayvan@APPLE.COM (Kayvan Sylvan) Newsgroups: gnu.emacs.bug Subject: filelock.c - No fchmod() on System V systems Message-ID: <8812011543.AA05277@satyr.UUCP> Date: 1 Dec 88 23:43:07 GMT Sender: daemon@tut.cis.ohio-state.edu Reply-To: satyr!kayvan@apple.com Distribution: gnu Organization: GNUs Not Usenet Lines: 34