diff options
author | Roland McGrath <roland@gnu.org> | 1995-03-09 10:00:12 +0000 |
---|---|---|
committer | Roland McGrath <roland@gnu.org> | 1995-03-09 10:00:12 +0000 |
commit | 6c2f050742cfb5b3ff6ee96b106409f541eb53bc (patch) | |
tree | f7296a81b8d5524dddfa0aa1cc24342d8ef9ac24 /time/emkdir.c | |
parent | 286351153566acc7dcc82834d90e0b8d87dff8be (diff) | |
download | glibc-6c2f050742cfb5b3ff6ee96b106409f541eb53bc.tar glibc-6c2f050742cfb5b3ff6ee96b106409f541eb53bc.tar.gz glibc-6c2f050742cfb5b3ff6ee96b106409f541eb53bc.tar.bz2 glibc-6c2f050742cfb5b3ff6ee96b106409f541eb53bc.zip |
Wed Mar 8 13:38:13 1995 Roland McGrath <roland@churchy.gnu.ai.mit.edu>
* posix/glob/configure.bat: Fixes from DJ.
* time/backward, time/europe, time/northamerica, time/pacificnew,
time/zdump.c, time/zic.c, time/tzfile.h, time/private.h,
time/ialloc.c: Code and data updated from ADO's 95b.
* time/emkdir.c: File removed.
* time/Makefile (distribute, extra-objs, zic): Omit it.
* time/localtime.c: Deansideclized. Never #define __tzname et al
to non-__ names.
* locale/lc-ctype.c (__ctype_tolower, __ctype_toupper): Use int *
instead of short int *.
* ctype/ctype-info.c: Likewise.
* ctype/ctype.h: Likewise.
* locale/langinfo.h (_NL_CTYPE_CLASS): Use this (just one) instead
of EB and EL versions.
Diffstat (limited to 'time/emkdir.c')
-rw-r--r-- | time/emkdir.c | 85 |
1 files changed, 0 insertions, 85 deletions
diff --git a/time/emkdir.c b/time/emkdir.c deleted file mode 100644 index 5cc62d29e2..0000000000 --- a/time/emkdir.c +++ /dev/null @@ -1,85 +0,0 @@ -#ifndef lint -#ifndef NOID -static char elsieid[] = "@(#)emkdir.c 8.23"; -#endif /* !defined NOID */ -#endif /* !defined lint */ - -#ifndef emkdir - -/*LINTLIBRARY*/ - -#include "private.h" - -extern char * imalloc P((int n)); -extern void ifree P((char * p)); - -static char * -quoted(name) -register const char * name; -{ - register char * result; - register char * cp; - register int c; - - if (name == NULL) - name = ""; - result = imalloc((int) (4 * strlen(name) + 3)); - if (result == NULL) - return NULL; - cp = result; -#ifdef unix - *cp++ = '\''; - while ((c = *name++) != '\0') - if (c == '\'') { - *cp++ = c; - *cp++ = '\\'; - *cp++ = c; - *cp++ = c; - } else *cp++ = c; - *cp++ = '\''; -#endif /* defined unix */ -#ifndef unix - while ((c = *name++) != '\0') - if (c == '/') - *cp++ = '\\'; - else *cp++ = c; -#endif /* !defined unix */ - *cp = '\0'; - return result; -} - -int -emkdir(name, mode) -const char * name; -const int mode; -{ - register int result; - register const char * format; - register char * command; - register char * qname; - - if ((qname = quoted(name)) == NULL) - return -1; -#ifdef unix - format = "mkdir 2>&- %s && chmod 2>&- %o %s"; -#endif /* defined unix */ -#ifndef unix - format = "mkdir %s"; -#endif /* !defined unix */ - command = imalloc((int) (strlen(format) + 2 * strlen(qname) + 20 + 1)); - if (command == NULL) { - ifree(qname); - return -1; - } - (void) sprintf(command, format, qname, mode, qname); - ifree(qname); - result = system(command); - ifree(command); - return (result == 0) ? 0 : -1; -} - -/* -** UNIX was a registered trademark of UNIX System Laboratories in 1993. -*/ - -#endif /* !defined emkdir */ |