lynx-dev
[Top][All Lists]
Advanced

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

Re: lynx-dev Lynx Litter on VMS


From: dickey
Subject: Re: lynx-dev Lynx Litter on VMS
Date: Wed, 14 Oct 1998 05:22:40 -0400 (EDT)

> +  
> + #ifdef VMS 
> +     /* 
> +      *  Get rid of any copies of the cookie file that VMS creates. 
> +      */ 
> +  
> +     StrAllocCopy(VMScookie_file, cookie_file); 
> +     StrAllocCat(VMScookie_file, ";-1"); 
> +  
> +     while (remove(VMScookie_file) == 0) ; 
> +         /* 
> +          *  Reset version number. 
> +          */ 
> +     StrAllocCopy(VMScookie_file, cookie_file); 
> +     StrAllocCat(VMScookie_file, ";1"); 
> +     rename(cookie_file, VMScookie_file);  
> + #endif /* VMS */ 

The last couple of lines are redundant and error-prone.  If the remove loop
fails due to permissions, you'll end up renaming the most recent file to a
lower version than the possible older file.  So I'd simply omit that.

(I'll add the first part to pre.10, since I don't see anything else
wrong)

> +  
>   } 
>   #endif 
>    
> --  
> Computers are useless.  They can only give you answers. 
>               -- Pablo Picasso 


-- 
Thomas E. Dickey
address@hidden
http://www.clark.net/pub/dickey

reply via email to

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