lynx-dev
[Top][All Lists]
Advanced

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

LYNX-DEV 2-7 can't follow absolute path to bookmark file


From: Will Mengarini
Subject: LYNX-DEV 2-7 can't follow absolute path to bookmark file
Date: Thu, 13 Feb 1997 10:15:01 -0800 (PST)

Under Lynx 2-6, my bookmark file was specified on the options menu as
"/u/s/seldon/bookmarks.htm".  When I tried to access it with 2-7, I was
told no file existed, & I needed to add a bookmark with "a".  The file
did exist in the specified location, & 2-6 was still able to access it
fine.  This happened with multiple bookmarks either disabled or enabled.

The clue came only when I enabled multiple bookmarks & tried
to access the definition for the default bookmark file;
Lynx flashed a note that I should use a file in my
home directory.  Well, /u/s/seldon *is* my home directory,
but removing that dirname allowed the file to be found.

I'm not sure what's happening here.  Perhaps it was intentional that
2-7 no longer allow absolute paths to bookmark files even though 2-6
did, possibly for some security reason.  If so, there will be a lot
of help requests of the form "Lynx 2-7 can't find my bookmark file",
possibly misleading less-tenacious users to falsely conclude that
the upgrade doesn't work.  It's plausible many users have absolute
paths, since I can recall why I did: it was necessary before SAVE_SPACE
was implemented in lynx.cfg, when I used to get my downloads into a
separate directory by running Lynx from a shell script that would
cd to that directory before starting Lynx.  So the bookmark file
was no longer in the current directory, & needed an absolute path.
I didn't think of twiddling the options menu after SAVE_SPACE was
defined & this kluge was no longer necessary; in particular, sometimes
I execute Lynx from subdirectories of $HOME, & I always want it to
reference the $HOME bookmark file, not a new one for each directory.

If absolute paths are now disallowed, what do relative paths mean?
Are they always relative to $HOME?  Will users be able to guess this
when Lynx tells them their bookmark files are empty, even though
they look at the option menu & see a correct path to a file they
know is a valid nonempty bookmark file?  Remember I only got a
clue when I tried messing with multi-bookmarks.  While they were
disabled (the default), all Lynx told me was, in effect, that the
file named in the options menu didn't exist, even though it did.

One other possibility may be relevant.  On my ISP $HOME = "/u/s/seldon",
& that's the correct way to refer to $HOME when it must be spelled out;
but actually, the physical path is "/u/u8/s/seldon", & the u8 should
always be omitted.  Is it possible 2-7 is getting the physical path
from someplace, comparing it to the dirname of the file, & finding that
the 2 don't match?  If Lynx gets $HOME from the environment variable,
& then calls getcwd() to check whether it's currently in $HOME, a
string comparison on those 2 paths will give the wrong answer.  (I'm
not sure how to get the right one; on Unix, perhaps you could compare
inode numbers for both paths.)  It may not be worth it for Lynx to
care whether it's in $HOME or referring to it, if this is the problem.

--
Will Mengarini <address@hidden> This .sig has been accessed [INLINE] times
;
; To UNSUBSCRIBE:  Send a mail message to address@hidden
;                  with "unsubscribe lynx-dev" (without the
;                  quotation marks) on a line by itself.
;

reply via email to

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