lynx-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: LYNX-DEV Enter f'name for Print to File: relative path vs dotfile;


From: Larry W. Virden, x2487
Subject: Re: LYNX-DEV Enter f'name for Print to File: relative path vs dotfile; edit previous
Date: Sun, 15 Mar 1998 06:27:15 -0500

Okay, here is a first stab at a fix for this.  HOWEVER, I don't know
VMS so I didn't attempt to fathom if there is a similar modification
needed there.

There are diffs based o LYNX 2.8rel3.  I did minimal testing of the
results, but confirmed that the cases I could think of seemed to
work as expected.

--- LYDownload.c.orig   Sun Mar 15 05:37:39 1998
+++ LYDownload.c        Sun Mar 15 06:18:04 1998
@@ -217,3 +217,5 @@
        if (no_dotfiles || !show_dotfiles) {
-         if (*buffer == '.' ||
+         if (((*buffer == '.') &&
+               ((strncmp(buffer, "../", 3) != 0) &&
+                (strncmp(buffer, "./", 2) != 0))) ||
 #ifdef VMS
@@ -498,3 +500,5 @@
                if (no_dotfiles || !show_dotfiles) {
-                   if (*buffer == '.' ||
+                   if (((*buffer == '.') &&
+                       ((strncmp(buffer, "../", 3) != 0) &&
+                        (strncmp(buffer, "./", 2) != 0))) ||
 #ifdef VMS
--- LYPrint.c.orig      Sun Mar 15 05:53:31 1998
+++ LYPrint.c   Sun Mar 15 06:18:57 1998
@@ -333,3 +333,5 @@
                if (no_dotfiles || !show_dotfiles) {
-                   if ((*filename == '.') ||
+                   if (((*filename == '.') &&
+                        ((strncmp(filename, "../", 3) != 0) &&
+                         (strncmp(filename, "./", 2) != 0))) ||
 #ifdef VMS
@@ -1142,3 +1144,5 @@
                        if (no_dotfiles || !show_dotfiles) {
-                           if ((*filename == '.') ||
+                           if (((*filename == '.') &&
+                               ((strncmp(filename, "../", 3) != 0) &&
+                                (strncmp(filename, "./", 2) != 0))) ||
 #ifdef VMS
-- 
Larry W. Virden                 INET: address@hidden
<URL:http://www.teraform.com/%7Elvirden/> <*> O- "We are all Kosh."
Unless explicitly stated to the contrary, nothing in this posting should 
be construed as representing my employer's opinions.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]