"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "lib/mkdir.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.).

mkdir.c  (le-1.16.5):mkdir.c  (le-1.16.6)
/* On some systems, mkdir ("foo/", 0700) fails because of the trailing /* On some systems, mkdir ("foo/", 0700) fails because of the trailing
slash. On those systems, this wrapper removes the trailing slash. slash. On those systems, this wrapper removes the trailing slash.
Copyright (C) 2001, 2003, 2006, 2008-2017 Free Software Foundation, Inc. Copyright (C) 2001, 2003, 2006, 2008-2019 Free Software Foundation, Inc.
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 Jim Meyering */ /* written by Jim Meyering */
#include <config.h> #include <config.h>
/* Specification. */ /* Specification. */
#include <sys/stat.h> #include <sys/stat.h>
#include <errno.h> #include <errno.h>
#include <stdio.h> #include <stdio.h>
skipping to change at line 41 skipping to change at line 41
#include "dirname.h" #include "dirname.h"
/* Disable the definition of mkdir to rpl_mkdir (from the <sys/stat.h> /* Disable the definition of mkdir to rpl_mkdir (from the <sys/stat.h>
substitute) in this file. Otherwise, we'd get an endless recursion. */ substitute) in this file. Otherwise, we'd get an endless recursion. */
#undef mkdir #undef mkdir
/* mingw's _mkdir() function has 1 argument, but we pass 2 arguments. /* mingw's _mkdir() function has 1 argument, but we pass 2 arguments.
Additionally, it declares _mkdir (and depending on compile flags, an Additionally, it declares _mkdir (and depending on compile flags, an
alias mkdir), only in the nonstandard includes <direct.h> and <io.h>, alias mkdir), only in the nonstandard includes <direct.h> and <io.h>,
which are included in the <sys/stat.h> override. */ which are included in the <sys/stat.h> override. */
#if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__ #if defined _WIN32 && ! defined __CYGWIN__
# define mkdir(name,mode) _mkdir (name) # define mkdir(name,mode) _mkdir (name)
# define maybe_unused _GL_UNUSED # define maybe_unused _GL_UNUSED
#else #else
# define maybe_unused /* empty */ # define maybe_unused /* empty */
#endif #endif
/* This function is required at least for NetBSD 1.5.2. */ /* This function is required at least for NetBSD 1.5.2. */
int int
rpl_mkdir (char const *dir, mode_t mode maybe_unused) rpl_mkdir (char const *dir, mode_t mode maybe_unused)
 End of changes. 3 change blocks. 
3 lines changed or deleted 3 lines changed or added

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