"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "lib/error.c" between
le-1.16.5.tar.gz and le-1.16.6.tar.gz

About: le is a terminal text editor (many block operations with stream and rectangular blocks, tunable syntax highlighting, etc.).

error.c  (le-1.16.5):error.c  (le-1.16.6)
/* Error handler for noninteractive utilities /* Error handler for noninteractive utilities
Copyright (C) 1990-1998, 2000-2007, 2009-2017 Free Software Foundation, Inc. Copyright (C) 1990-1998, 2000-2007, 2009-2019 Free Software Foundation, Inc.
This file is part of the GNU C Library. This file is part of the GNU C Library.
This program is free software: you can redistribute it and/or modify This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or the Free Software Foundation; either version 3 of the License, or
(at your option) any later version. (at your option) any later version.
This program is distributed in the hope that it will be useful, This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details. GNU General Public License for more details.
You should have received a copy of the GNU General Public License You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */ along with this program. If not, see <https://www.gnu.org/licenses/>. */
/* Written by David MacKenzie <djm@gnu.ai.mit.edu>. */ /* Written by David MacKenzie <djm@gnu.ai.mit.edu>. */
#if !_LIBC #if !_LIBC
# include <config.h> # include <config.h>
#endif #endif
#include "error.h" #include "error.h"
#include <stdarg.h> #include <stdarg.h>
skipping to change at line 96 skipping to change at line 96
# undef putc # undef putc
# define putc(c, fp) _IO_putc (c, fp) # define putc(c, fp) _IO_putc (c, fp)
# include <bits/libc-lock.h> # include <bits/libc-lock.h>
#else /* not _LIBC */ #else /* not _LIBC */
# include <fcntl.h> # include <fcntl.h>
# include <unistd.h> # include <unistd.h>
# if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__ # if defined _WIN32 && ! defined __CYGWIN__
/* Get declarations of the native Windows API functions. */ /* Get declarations of the native Windows API functions. */
# define WIN32_LEAN_AND_MEAN # define WIN32_LEAN_AND_MEAN
# include <windows.h> # include <windows.h>
/* Get _get_osfhandle. */ /* Get _get_osfhandle. */
# if GNULIB_MSVC_NOTHROW # if GNULIB_MSVC_NOTHROW
# include "msvc-nothrow.h" # include "msvc-nothrow.h"
# else # else
# include <io.h> # include <io.h>
# endif # endif
# endif # endif
skipping to change at line 134 skipping to change at line 134
# if GNULIB_STRERROR_R_POSIX || HAVE_STRERROR_R || defined strerror_r # if GNULIB_STRERROR_R_POSIX || HAVE_STRERROR_R || defined strerror_r
# define __strerror_r strerror_r # define __strerror_r strerror_r
# endif /* GNULIB_STRERROR_R_POSIX || HAVE_STRERROR_R || defined strerror_r */ # endif /* GNULIB_STRERROR_R_POSIX || HAVE_STRERROR_R || defined strerror_r */
#endif /* not _LIBC */ #endif /* not _LIBC */
#if !_LIBC #if !_LIBC
/* Return non-zero if FD is open. */ /* Return non-zero if FD is open. */
static int static int
is_open (int fd) is_open (int fd)
{ {
# if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__ # if defined _WIN32 && ! defined __CYGWIN__
/* On native Windows: The initial state of unassigned standard file /* On native Windows: The initial state of unassigned standard file
descriptors is that they are open but point to an INVALID_HANDLE_VALUE. descriptors is that they are open but point to an INVALID_HANDLE_VALUE.
There is no fcntl, and the gnulib replacement fcntl does not support There is no fcntl, and the gnulib replacement fcntl does not support
F_GETFL. */ F_GETFL. */
return (HANDLE) _get_osfhandle (fd) != INVALID_HANDLE_VALUE; return (HANDLE) _get_osfhandle (fd) != INVALID_HANDLE_VALUE;
# else # else
# ifndef F_GETFL # ifndef F_GETFL
# error Please port fcntl to your platform # error Please port fcntl to your platform
# endif # endif
return 0 <= fcntl (fd, F_GETFL); return 0 <= fcntl (fd, F_GETFL);
 End of changes. 4 change blocks. 
4 lines changed or deleted 4 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)