From: Ulrich Drepper Date: Sat, 6 Apr 2002 03:49:35 +0000 (+0000) Subject: Update from tzcode2002c. X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f012319a200abefd280ce73c34093bfb911bbcaa;p=thirdparty%2Fglibc.git Update from tzcode2002c. --- diff --git a/timezone/zic.c b/timezone/zic.c index 6fdcfcb66a8..64642b39c59 100644 --- a/timezone/zic.c +++ b/timezone/zic.c @@ -1,6 +1,6 @@ #ifndef lint #ifndef NOID -static char elsieid[] = "@(#)zic.c 7.104"; +static char elsieid[] = "@(#)zic.c 7.107"; #endif /* !defined NOID */ #endif /* !defined lint */ @@ -621,9 +621,11 @@ const char * const tofile; result = link(fromname, toname); #if (HAVE_SYMLINK - 0) - if (result != 0) { + if (result != 0 && + access(fromname, F_OK) == 0 && + !itsdir(fromname)) { const char *s = tofile; - register char *symlinkcontents = NULL; + register char * symlinkcontents = NULL; while ((s = strchr(s+1, '/')) != NULL) symlinkcontents = ecatalloc(symlinkcontents, "../"); symlinkcontents = ecatalloc(symlinkcontents, fromname);