lynx-dev
[Top][All Lists]
Advanced

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

lynx-dev storing cookies for -dump/-source (was: libreadline)


From: Klaus Weide
Subject: lynx-dev storing cookies for -dump/-source (was: libreadline)
Date: Sun, 12 Dec 1999 15:08:56 -0600 (CST)

On Sat, 11 Dec 1999, Vlad Harchev wrote:
> On Sun, 12 Dec 1999, brian j pardy wrote:
> > I'd rather not do an if(!unix && writefile != /dev/null) writecookies; 
> > sort of thing -- has anyone solved this problem before?
> 
>  Cygwin and DJGPP support "/dev/null" as filename. For other windows builds
> (that don't use Cygwin) of course NULL could be used - this means that we
>  should define  NULL_FILE_NAME to be the name of NULL device and usef it. As 
> for VMS, OS/2 Mac, I don't know - but may be using illegal file descriptor
> (that doesn't correspond to opened file) could solve the problem. Using 
> wrappers could also solve the problem, like this:
>  typedef struct _LYFILE
>  {
>       FILE* f;
>       BOOL is_null;
>  } LYFILE;
>  int LYfread(char* buf,int size,int nmemb,LYFILE*);

You are thinking much too complicated here.  We're only talking about
writing the file anyway.

All that should be needed is something like

   if (!strcmp(store_cookie_file, "/dev/null"))
       return;

near the top of LYStoreCookies.

   Klaus


reply via email to

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