Date: Sat, 15 Sep 2001 10:47:23 +0300 From: "Eli Zaretskii" Sender: halo1 AT zahav DOT net DOT il To: Paula Sanchez Message-Id: <3405-Sat15Sep2001104722+0300-eliz@is.elta.co.il> X-Mailer: Emacs 20.6 (via feedmail 8.3.emacs20_6 I) and Blat ver 1.8.9 CC: djgpp AT delorie DOT com In-reply-to: (message from Paula Sanchez on Fri, 14 Sep 2001 12:27:46 -0600) Subject: Re: fcntl References: Reply-To: djgpp AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: djgpp AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk > From: Paula Sanchez > Newsgroups: comp.os.msdos.djgpp > Date: Fri, 14 Sep 2001 12:27:46 -0600 > > I started using DJGPP this week. I am trying to block, unblock and check > the lock in a file with the function fcntl. > > I am booting DOS version Windows 95 4.00.1111 and using the DOS DJGPP GCC > 2.953. > > It is defined in libc and I assumed that is linked by default. > > I am getting this error for any of the tries of locking, unlocking and > checking the lock: > Error locking: Function not implemented (ENOSYS) F_GETLK and F_SETLK commands for `fcntl' are clearly documented in the library reference to always fail in DJGPP v2.03. That's what ENOSYS is trying to tell you. The code to support these commands was added to the current development sources, but the latest released version doesn't have it. For now, you can use `lock'/`unlock' or `_dos_lock'/`_dos_unlock' functions to get the same functionality.