FDclone 2.09a patch [3/3]
しらいです。
file & directory 管理ツール FDclone 2.09a の patch その 3
です。
Submitted-by: shirai@chandra2
Archive-name: FD-2.09a.patch/part03
---- Cut Here and feed the following to sh ----
#!/bin/sh
# This is `FD-2.09a.shar.03' (part 3 of FD-2.09a.patch).
# Do not concatenate these parts, unpack them in order with `/bin/sh'.
# File `FD-2.09a.patch' is being continued...
#
echo=echo
touch -am 1231235999 $$.touch >/dev/null 2>&1
if test ! -f 1231235999 && test -f $$.touch; then
shar_touch=touch
else
shar_touch=:
echo
$echo 'WARNING: not restoring timestamps. Consider getting and'
$echo "installing GNU \`touch', distributed in GNU File Utilities..."
echo
fi
rm -f 1231235999 $$.touch
#
if test ! -r _sh00584/seq; then
$echo 'Please unpack part 1 first!'
exit 1
fi
shar_sequence=`cat _sh00584/seq`
if test "$shar_sequence" != 3; then
$echo 'Please unpack part' "$shar_sequence" 'next!'
exit 1
fi
if test ! -f _sh00584/new; then
$echo 'x -' 'STILL SKIPPING' 'FD-2.09a.patch'
else
$echo 'x -' 'continuing file' 'FD-2.09a.patch'
sed 's/^X//' << 'SHAR_EOF' >> FD-2.09a.patch &&
X if (!kbhit2(WAITKEYPAD * 1000L) || (ch = getch2()) == EOF)
X return(key);
X }
@@ -3037,18 +3036,18 @@
X return(key);
X }
X
-int getkey3(sig)
-int sig;
+int getkey3(sig, code)
+int sig, code;
X {
X int ch;
X
- if ((ch = getkey2(sig)) < 0) return(ch);
+ if ((ch = getkey2(sig, code)) < 0) return(ch);
X if (ch >= K_F('*') && ch < K_DL) {
X if (ch == K_F('?')) ch = K_CR;
X else ch -= K_F0;
X }
X
- return(ch & 01777);
+ return(ch & ~K_ALTERNATE);
X }
X
X int ungetch2(c)
@@ -3060,10 +3059,9 @@
X ch = c;
X Xioctl(ttyio, TIOCSTI, &ch);
X # else
- if (ungetnum >= arraysize(ungetbuf) - 1) return(EOF);
- if (ungetnum)
- memmove((char *)&(ungetbuf[1]), (char *)&(ungetbuf[0]),
- ungetnum * sizeof(u_char));
+ if (ungetnum >= arraysize(ungetbuf)) return(EOF);
+ memmove((char *)&(ungetbuf[1]), (char *)&(ungetbuf[0]),
+ ungetnum * sizeof(u_char));
X ungetbuf[0] = c;
X ungetnum++;
X # endif
diff -urNP ../FD-2.09/term.h ./term.h
--- ../FD-2.09/term.h Tue Aug 22 00:00:00 2006
+++ ./term.h Tue Oct 31 00:00:00 2006
@@ -74,6 +74,7 @@
X #define K_MAX K_HELP
X
X #define K_METAKEY 01000
+#define K_ALTERNATE 02000
X #if MSDOS
X #define mkmetakey(c) (K_METAKEY | (tolower2(c) & 0x7f))
X #define ismetakey(c) (((c) & K_METAKEY) && islower2((c) & 0xff))
@@ -203,11 +204,11 @@
X #endif
X extern int kbhit2 __P_((long));
X extern int getch2 __P_((VOID_A));
-extern int getkey2 __P_((int));
+extern int getkey2 __P_((int, int));
X #if MSDOS
X #define getkey3 getkey2
X #else
-extern int getkey3 __P_((int));
+extern int getkey3 __P_((int, int));
X #endif
X extern int ungetch2 __P_((int));
X extern int setscroll __P_((int, int));
diff -urNP ../FD-2.09/tree.c ./tree.c
--- ../FD-2.09/tree.c Tue Aug 22 00:00:00 2006
+++ ./tree.c Tue Oct 31 00:00:00 2006
@@ -127,20 +127,20 @@
X treelist *list, *parent;
X int level, *maxp;
X {
+#ifdef _USEDOSEMU
+ char tmp[MAXPATHLEN];
+#endif
X DIR *dirp;
X struct dirent *dp;
X struct stat st;
X char *cp, *dir, *subdir, cwd[MAXPATHLEN];
-#ifdef _USEDOSEMU
- char tmp[MAXPATHLEN];
-#endif
X int i, len;
X
X if ((level + 1) * DIRFIELD + 2 > TREEFIELD) {
X *maxp = -2;
X return(NULL);
X }
- if (intrkey()) {
+ if (intrkey(K_ESC)) {
X *maxp = -1;
X return(NULL);
X }
@@ -149,29 +149,26 @@
X return(NULL);
X }
X
-#if MSDOS
- if (_dospath(path)) path += 2;
-#endif
- if (*path == _SC_) {
- dir = strdup2(rootpath);
- subdir = path + 1;
- if (!*subdir) subdir = NULL;
- }
-#ifdef _USEDOSEMU
- else if (_dospath(path)) {
- dir = strndup2(path, 3);
- subdir = path + 3;
- if (!*subdir) subdir = NULL;
- }
-#endif
- else {
- len = (cp = strdelim(path, 0)) ? cp - path : strlen(path);
- dir = strndup2(path, len);
- subdir = (cp) ? cp + 1 : NULL;
- }
+ cp = path;
+#ifdef _USEDOSPATH
+ if (_dospath(cp)) cp += 2;
+#endif
+#ifdef DOUBLESLASH
+ if ((len = isdslash(path))) cp = &(path[len]);
+ else
+#endif
+ if (*cp == _SC_) cp++;
+ else cp = strdelim(path, 0);
+ len = (cp) ? cp - path : strlen(path);
+
+ dir = strndup2(path, len);
+ subdir = &(path[len]);
+ if (*subdir == _SC_) subdir++;
+ else if (!*subdir) subdir = NULL;
X
X if (!subdir) len = 0;
- else len = (cp = strdelim(subdir, 0)) ? cp - subdir : strlen(subdir);
+ else if ((cp = strdelim(subdir, 0))) len = cp - subdir;
+ else len = strlen(subdir);
X
X *maxp = 0;
X i = _chdir2(dir);
@@ -180,10 +177,11 @@
X
X i = 0;
X while ((dp = Xreaddir(dirp))) {
- if (isdotdir(dp -> d_name)
- || Xstat(nodospath(tmp, dp -> d_name), &st) < 0
+ if (isdotdir(dp -> d_name)) continue;
+ else if (Xstat(nodospath(tmp, dp -> d_name), &st) < 0
X || !s_isdir(&st))
X continue;
+
X list = b_realloc(list, *maxp, treelist);
X if (!subdir) {
X list[*maxp].name = strdup2(dp -> d_name);
@@ -197,7 +195,7 @@
X (*maxp)++;
X }
X else if (!strnpathcmp(dp -> d_name, subdir, len)
- && strlen(dp -> d_name) == len) {
+ && !(dp -> d_name[len])) {
X list[0].name = strdup2(dp -> d_name);
X list[0].sub = &(list[0]);
X list[0].max = 0;
@@ -234,6 +232,7 @@
X }
X }
X Xclosedir(dirp);
+
X if (list) for (i = 0; i < *maxp; i++) {
X #ifndef NODIRLOOP
X treelist *lp;
@@ -383,28 +382,12 @@
X if (tmplp) {
X lp = (tmplp == tr_root) ? &(list[i]) : tmplp;
X len = strlen(list[i].name);
-#if MSDOS
- if (!_dospath(list[i].name)
- || list[i].name[2] != _SC_)
- len++;
- memmove(&(treepath[len]), treepath,
+ if (len > 0 && list[i].name[len - 1] == _SC_)
+ len--;
+ memmove(&(treepath[len + 1]), treepath,
X strlen(treepath) + 1);
- memcpy(treepath, list[i].name, len - 1);
-#else /* !MSDOS */
-# ifdef _NODOSDRIVE
- if (*list[i].name != _SC_) len++;
-# else
- if (*list[i].name != _SC_
- && !_dospath(list[i].name))
- len++;
-# endif
- memmove(&(treepath[len]), treepath,
- strlen(treepath) + 1);
- if (*list[i].name != _SC_)
- memcpy(treepath, list[i].name,
- len - 1);
-#endif /* !MSDOS */
- treepath[len - 1] = _SC_;
+ memcpy(treepath, list[i].name, len);
+ treepath[len] = _SC_;
X }
X }
X }
@@ -485,8 +468,8 @@
X if (!list || list -> max >= 0) return(1);
X if (!expandtree(list)) return(0);
X if (!(list -> sub)) return(1);
- cp = treepath + strlen(treepath);
- if (cp > treepath + 1) {
+ cp = &(treepath[strlen(treepath)]);
+ if (cp > &(treepath[1])) {
X strcatdelim(treepath);
X cp++;
X }
@@ -531,7 +514,11 @@
X return(0);
X
X waitmes();
- if ((cp = strrdelim(treepath, 0)) == strdelim(treepath, 0)) cp++;
+ cp = strrdelim(treepath, 0);
+ if (cp == treepath) cp++;
+#ifdef DOUBLESLASH
+ else if (cp - treepath < isdslash(treepath)) cp++;
+#endif
X *cp = '\0';
X if (!expandtree(tr_cur)) {
X tr_line = oy;
@@ -725,7 +712,7 @@
X # endif
X #endif
X char *cp, *cwd, path[MAXPATHLEN];
- int ch, min, oy, otop;
+ int ch, min, len, oy, otop;
X
X keyflush();
X waitmes();
@@ -738,22 +725,24 @@
X tr_root -> parent = NULL;
X #endif
X treepath = path;
+
+#ifdef _USEDOSEMU
+ if (dospath(nullstr, path)) len = 3;
+ else
+#endif
+ {
+#ifdef DOUBLESLASH
+ if ((len = isdslash(fullpath))) /*EMPTY*/;
+ else
+#endif
X #if MSDOS
- tr_cur[0].name = malloc2(3 + 1);
- strcpy(path, fullpath);
- strncpy2(tr_cur[0].name, path, 3);
-#else /* !MSDOS */
-# ifdef _NODOSDRIVE
- strcpy(path, fullpath);
- tr_cur[0].name = strdup2(rootpath);
-# else
- if (dospath(nullstr, path)) tr_cur[0].name = strndup2(path, 3);
- else {
+ len = 3;
+#else
+ len = 1;
+#endif
X strcpy(path, fullpath);
- tr_cur[0].name = strdup2(rootpath);
X }
-# endif
-#endif /* !MSDOS */
+ tr_cur[0].name = strndup2(path, len);
X
X #ifndef NODIRLOOP
X if (Xstat(nodospath(tmp, tr_cur[0].name), &st) < 0)
@@ -768,14 +757,9 @@
X 0, &(tr_cur[0].max));
X
X tr_line = 0;
-#if MSDOS
- cwd = path + 2;
-#else /* !MSDOS */
- cwd = path;
-# ifndef _NODOSDRIVE
- if (_dospath(cwd)) cwd += 2;
-# endif
-#endif /* !MSDOS */
+ if (path[len - 1] == _SC_) len--;
+ cwd = &(path[len]);
+
X if (isrootpath(cwd)) /*EMPTY*/;
X else for (cp = cwd; (cp = strdelim(cp, 0)); cp++, tr_line++)
X if ((tr_line + 1) * DIRFIELD + 2 > TREEFIELD
diff -urNP ../FD-2.09/types.h ./types.h
--- ../FD-2.09/types.h Tue Aug 22 00:00:00 2006
+++ ./types.h Tue Oct 31 00:00:00 2006
@@ -156,6 +156,7 @@
X #define LCK_FLOCK 0001
X #define LCK_INVALID 0002
X #define LCK_STREAM 0004
+#define LCK_MAXRETRY 32
X
X typedef struct _bindtable {
X short key;
@@ -425,6 +426,7 @@
X #define TCH_CHANGE 00100
X #define TCH_MASK 00200
X #define TCH_MODEEXE 00400
+#define TCH_IGNOREERR 01000
X
X #define ATR_EXCLUSIVE 3
X #define ATR_MODEONLY 1
diff -urNP ../FD-2.09/unixdisk.c ./unixdisk.c
--- ../FD-2.09/unixdisk.c Tue Aug 22 00:00:00 2006
+++ ./unixdisk.c Tue Oct 31 00:00:00 2006
@@ -45,6 +45,9 @@
X extern char *strcatdelim __P_((char *));
X extern char *strcatdelim2 __P_((char *, char *, char *));
X extern int isdotdir __P_((char *));
+# ifdef DOUBLESLASH
+extern int isdslash __P_((char *));
+# endif
X extern char curpath[];
X #else
X static int NEAR _dospath __P_((char *));
@@ -55,6 +58,9 @@
X static char *NEAR strcatdelim __P_((char *));
X static char *NEAR strcatdelim2 __P_((char *, char *, char *));
X static int NEAR isdotdir __P_((char *));
+# ifdef DOUBLESLASH
+static int isdslash __P_((char *));
+# endif
X static char curpath[] = ".";
X #endif
X
@@ -96,6 +102,8 @@
X #ifndef _NOUSELFN
X static int NEAR putdostime __P_((u_short *, u_short *, time_t));
X #endif
+static int NEAR alter_findfirst __P_((char *, u_int *,
+ struct dosfind_t *, struct lfnfind_t *));
X
X #ifndef _NODOSDRIVE
X int dosdrive = 0;
@@ -144,6 +152,9 @@
X };
X static int (far *doint25)__P_((VOID_A)) = NULL;
X #endif /* !DJGPP && !_NODOSDRIVE */
+#ifdef DOUBLESLASH
+static int dsdrive = 0;
+#endif
X
X
X #ifndef FD
@@ -316,6 +327,19 @@
X
X return(0);
X }
+
+# ifdef DOUBLESLASH
+static int isdslash(s)
+char *s;
+{
+ char *cp;
+
+ if (s[0] != _SC_ || s[1] != _SC_ || !s[2] || s[2] == _SC_) return(0);
+ if ((cp = strdelim(&(s[2]), 0))) return(cp - s);
+
+ return(strlen(s));
+}
+# endif /* DOUBLESLASH */
X #endif /* !FD */
X
X #ifdef DJGPP
@@ -335,6 +359,9 @@
X static char *NEAR duplpath(path)
X char *path;
X {
+#ifdef DOUBLESLASH
+ int len;
+#endif
X static char buf[MAXPATHLEN];
X int i, j, ps;
X
@@ -344,6 +371,13 @@
X buf[j++] = path[i++];
X buf[j++] = path[i++];
X }
+#ifdef DOUBLESLASH
+ if ((len = isdslash(path))) {
+ memcpy(buf, path, len);
+ i = j = len;
+ }
+ else
+#endif
X if (path[i] == _SC_) buf[j++] = path[i++];
X for (; path[i]; i++) {
X if (path[i] == _SC_) ps = 1;
@@ -365,6 +399,9 @@
X {
X int drive;
X
+#ifdef DOUBLESLASH
+ if (dsdrive) return(dsdrive);
+#endif
X drive = (dos7access & D7_CAPITAL) ? 'A' : 'a';
X #ifndef _NODOSDRIVE
X if (lastdrive >= 0) drive += toupper2(lastdrive) - 'A';
@@ -386,6 +423,14 @@
X char *path;
X int drv, olddrv;
X
+#ifdef DOUBLESLASH
+ if (drive == '_') {
+ dsdrive = drive;
+ return(0);
+ }
+ dsdrive = '\0';
+#endif
+
X errno = EINVAL;
X if (islower2(drive)) {
X drv = drive - 'a';
@@ -460,6 +505,7 @@
X }
X
X /*
+ * 3: enable LFN access, but shared folder
X * 2: enable LFN access, but FAT32
X * 1: enable LFN access
X * 0: do SFN access
@@ -476,7 +522,13 @@
X __dpmi_regs reg;
X char drive, drv[4], buf[128];
X
+#ifdef DOUBLESLASH
+ if (isdslash(path)) return(3);
+#endif
X if (!path || !(drive = _dospath(path))) drive = getcurdrv();
+#ifdef DOUBLESLASH
+ if (drive == '_') return(3);
+#endif
X #ifndef _NODOSDRIVE
X if (checkdrive(toupper2(drive) - 'A') > 0) return(-2);
X #endif
@@ -595,6 +647,9 @@
X # ifndef BSPATHDELIM
X adjustpname(alias);
X # endif
+# ifdef DOUBLESLASH
+ if (isdslash(alias)) return(alias);
+# endif
X
X if (!path || !(i = _dospath(path))) i = getcurdrv();
X if (islower2(i)) *alias = tolower2(*alias);
@@ -619,6 +674,7 @@
X reg.x.cx = 0;
X #else /* !_NOUSELFN */
X switch (supportLFN(path)) {
+ case 3:
X case 2:
X case 1:
X reg.x.ax = 0x7160;
@@ -660,6 +716,9 @@
X #ifndef BSPATHDELIM
X adjustpname(resolved);
X #endif
+#ifdef DOUBLESLASH
+ if (isdslash(resolved)) return(resolved);
+#endif
X
X if (!path || !(i = _dospath(path))) i = getcurdrv();
X else path += 2;
@@ -1552,7 +1611,10 @@
X #endif
X sreg.ds = PTR_SEG(path);
X reg.x.dx = PTR_OFF(path, sizeof(struct dosfind_t));
- if (int21call(®, &sreg) < 0) return(-1);
+ if (int21call(®, &sreg) < 0) {
+ if (!errno) errno = ENOENT;
+ return(-1);
+ }
X #ifdef DJGPP
X dosmemget(__tb, sizeof(struct dosfind_t), result);
X #endif
@@ -1604,7 +1666,10 @@
X reg.x.dx = PTR_OFF(path, sizeof(struct lfnfind_t));
X sreg.es = PTR_SEG(result);
X reg.x.di = PTR_OFF(result, 0);
- if (int21call(®, &sreg) < 0) return(-1);
+ if (int21call(®, &sreg) < 0) {
+ if (!errno) errno = ENOENT;
+ return(-1);
+ }
X *fdp = reg.x.ax;
X #ifdef DJGPP
X dosmemget(__tb, sizeof(struct lfnfind_t), result);
@@ -2132,6 +2197,7 @@
X #ifdef DJGPP
X char tmp[MAXPATHLEN];
X #endif
+ char *cp;
X int drive;
X
X drive = getcurdrv();
@@ -2141,9 +2207,15 @@
X }
X else
X #endif
- if ((!pathname && !(pathname = (char *)malloc(size)))
- || !unixgetcurdir(gendospath(pathname, drive, _SC_), 0))
- return(NULL);
+ if (!pathname && !(pathname = (char *)malloc(size))) return(NULL);
+ else {
+#ifdef DOUBLESLASH
+ if (drive == '_') cp = pathname;
+ else
+#endif
+ cp = gendospath(pathname, drive, _SC_);
+ if (!unixgetcurdir(cp, 0)) return(NULL);
+ }
X
X *pathname = (dos7access & D7_CAPITAL)
X ? toupper2(*pathname) : tolower2(*pathname);
@@ -2256,7 +2328,7 @@
X }
X else
X # endif
- if (i == 2) {
+ if (i >= 2) {
X reg.x.ax = 0x7303;
X reg.x.cx = sizeof(fsbuf);
X # ifdef DJGPP
@@ -2304,58 +2376,83 @@
X return(0);
X }
X
+/*ARGSUSED*/
+static int NEAR alter_findfirst(path, fdp, dbuf, lbuf)
+char *path;
+u_int *fdp;
+struct dosfind_t *dbuf;
+struct lfnfind_t *lbuf;
+{
+ char *cp, tmp[MAXPATHLEN];
+ int n, len;
+
+#ifndef _NOUSELFN
+ if (fdp) n = lfn_findfirst(fdp, path, SEARCHATTRS, lbuf);
+ else
+#endif
+ n = dos_findfirst(path, SEARCHATTRS, dbuf);
+ if (n >= 0) return(n);
+ if (errno != ENOENT) return(-1);
+
+ if ((cp = strrdelim(path, 1))) cp++;
+ else cp = path;
+
+ if (isdotdir(cp) == 1) {
+ len = cp - path;
+ memcpy(tmp, path, len);
+ strcpy(&(tmp[len]), curpath);
+#ifndef _NOUSELFN
+ if (fdp) n = lfn_findfirst(fdp, tmp, SEARCHATTRS, lbuf);
+ else
+#endif
+ n = dos_findfirst(tmp, SEARCHATTRS, dbuf);
+ }
+#ifdef DOUBLESLASH
+ else {
+ if (isdslash(path)) return(-1);
+ else if (_dospath(path)) /*EMPTY*/;
+ else if (getcurdrv() == '_') return(-1);
+#endif
+ n = dos_findfirst(path, DS_IFLABEL, dbuf);
+ }
+
+ return(n);
+}
+
X int unixstat(path, stp)
X char *path;
X struct stat *stp;
X {
X #ifndef _NOUSELFN
+# ifndef _NODOSDRIVE
+ char buf[MAXPATHLEN];
+# endif
X struct lfnfind_t lbuf;
X u_int fd;
-#endif
+#endif /* !_NOUSELFN */
X struct dosfind_t dbuf;
X int i;
X
-#ifdef _NOUSELFN
- if ((i = dos_findfirst(path, SEARCHATTRS, &dbuf)) < 0) {
- if (errno && errno != ENOENT) return(-1);
- if (isdotdir(path) == 1)
- i = dos_findfirst(curpath, SEARCHATTRS, &dbuf);
- else i = dos_findfirst(path, DS_IFLABEL, &dbuf);
+ if (strpbrk(path, "*?")) {
+ errno = ENOENT;
+ return(-1);
X }
+#ifdef _NOUSELFN
+ i = alter_findfirst(path, NULL, &dbuf, NULL);
X #else /* !_NOUSELFN */
+ fd = (u_int)-1;
X i = supportLFN(path);
X # ifndef _NODOSDRIVE
X if (i < 0 && i > -3) {
- char buf[MAXPATHLEN];
-
X dependdosfunc = 0;
X if (dosstat(regpath(path, buf), stp) >= 0) return(0);
X else if (!dependdosfunc) return(-1);
X }
-# endif /* !_NODOSDRIVE */
- if (i <= 0) {
- fd = (u_int)-1;
- if ((i = dos_findfirst(path, SEARCHATTRS, &dbuf)) < 0) {
- if (errno && errno != ENOENT) return(-1);
- if (isdotdir(path) == 1)
- i = dos_findfirst(curpath, SEARCHATTRS, &dbuf);
- else i = dos_findfirst(path, DS_IFLABEL, &dbuf);
- }
- }
- else {
- if ((i = lfn_findfirst(&fd, path, SEARCHATTRS, &lbuf)) < 0) {
- if (errno && errno != ENOENT) return(-1);
- if (isdotdir(path) == 1)
- i = lfn_findfirst(&fd, curpath,
- SEARCHATTRS, &lbuf);
- else i = dos_findfirst(path, DS_IFLABEL, &dbuf);
- }
- }
+# endif
+ if (i <= 0) i = alter_findfirst(path, NULL, &dbuf, &lbuf);
+ else i = alter_findfirst(path, &fd, &dbuf, &lbuf);
X #endif /* !_NOUSELFN */
- if (i < 0) {
- if (!errno) errno = ENOENT;
- return(-1);
- }
+ if (i < 0) return(-1);
X
X #ifndef _NOUSELFN
X if (fd != (u_int)-1) {
@@ -2541,7 +2638,7 @@
X char *path, *type;
X {
X FILE *fp;
- int i, flags;
+ int i, fd, flags;
X
X path = duplpath(path);
X i = supportLFN(path);
@@ -2580,8 +2677,8 @@
X break;
X }
X
- if ((i = unixopen(path, flags, 0666)) < 0) return(NULL);
+ if ((fd = unixopen(path, flags, 0666)) < 0) return(NULL);
X
- return(fdopen(i, type));
+ return(fdopen(fd, type));
X }
X #endif /* !_NOUSELFN */
diff -urNP ../FD-2.09/unixemu.c ./unixemu.c
--- ../FD-2.09/unixemu.c Tue Aug 22 00:00:00 2006
+++ ./unixemu.c Tue Oct 31 00:00:00 2006
@@ -54,11 +54,15 @@
X }
X if (buf) {
X #ifndef _NOUSELFN
- if (shortname(path, buf) == buf);
+ if (shortname(path, buf) == buf) /*EMPTY*/;
X else
X #endif
- strcpy(buf, path);
+ unixrealpath(path, buf);
X }
+#ifdef DOUBLESLASH
+ if (isdslash(path)) drv = '_';
+ else
+#endif
X drv = _dospath(path);
X
X return((drv) ? drv : getcurdrv());
@@ -80,9 +84,9 @@
X int dospath3(path)
X char *path;
X {
- int drive;
+ int i, drive;
X
- if ((drive = supportLFN(path)) >= 0 || drive <= -3) return(0);
+ if ((i = supportLFN(path)) >= 0 || i <= -3) return(0);
X
X return((drive = _dospath(path)) ? drive : getcurdrv());
X }
@@ -93,6 +97,9 @@
X char *cp, tmp[MAXPATHLEN];
X int i, drive;
X
+#ifdef DOUBLESLASH
+ if (isdslash(path)) return(0);
+#endif
X if ((drive = _dospath(path))) cp = path + 2;
X else {
X cp = path;
diff -urNP ../FD-2.09/version.h ./version.h
--- ../FD-2.09/version.h Tue Aug 22 00:00:00 2006
+++ ./version.h Tue Oct 31 00:00:00 2006
@@ -5,4 +5,4 @@
X */
X
X char *distributor = NULL;
-static char version[] = "@(#)fd.c 2.09 08/22/06";
+static char version[] = "@(#)fd.c 2.09a 10/31/06";
SHAR_EOF
$echo 'File' 'FD-2.09a.patch' 'is complete' &&
$shar_touch -am 10240110106 'FD-2.09a.patch' &&
chmod 0644 'FD-2.09a.patch' ||
$echo 'restore of' 'FD-2.09a.patch' 'failed'
if ( md5sum --help 2>&1 | grep 'sage: md5sum \[' ) >/dev/null 2>&1 \
&& ( md5sum --version 2>&1 | grep -v 'textutils 1.12' ) >/dev/null; then
md5sum -c << SHAR_EOF >/dev/null 2>&1 \
|| $echo 'FD-2.09a.patch:' 'MD5 check failed'
7f1374525871384601bf4b34e5befa3c FD-2.09a.patch
SHAR_EOF
else
shar_count="`LC_ALL= LC_CTYPE= LANG= wc -c < 'FD-2.09a.patch'`"
test 113842 -eq "$shar_count" ||
$echo 'FD-2.09a.patch:' 'original size' '113842,' 'current size' "$shar_count!"
fi
fi
$echo 'You have unpacked the last part'
rm -fr _sh00584
exit 0
--
しらい たかし
Fnews-brouse 1.9(20180406) -- by Mizuno, MWE <mwe@ccsf.jp>
GnuPG Key ID = ECC8A735
GnuPG Key fingerprint = 9BE6 B9E9 55A5 A499 CD51 946E 9BDC 7870 ECC8 A735