[Top][All Lists]

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

Re: [Nano-devel] Er, another big patch ...

From: David Benbennick
Subject: Re: [Nano-devel] Er, another big patch ...
Date: Mon, 7 Oct 2002 04:46:22 -0400
User-agent: Mutt/

On Sun, Oct 06, 2002 at 10:05:39AM -0700, David Lawrence Ramsey wrote:
> I have one question about open_prevnext_file(): why did you make it a
> void function?  If open_files doesn't exist (which should never happen),
> it will now return nothing, and open_[prev|next]file_void() will call it
> and then return 0 as though nothing is wrong.  Leaving it an int
> function and letting it return 1, and then letting
> open_[prev|next]file_void() return that value, will make it more obvious
> that something has happened that shouldn't.

In CVS, the return value of open_nextfile() is used only by
close_open_file().  The patch gets the same behavior by having
close_open_file() just check directly whether there are multiple files

Is it really true that open_files will always be non-NULL at that point? 
If so, I guess there should be something like assert(open_files) there.

By the way, I think the return value of the shortcut functions, like
open_prevfile_void(), is always ignored anyway.

> Would you, please?  Thanks.


Attachment: pgpIYdzR_fbJG.pgp
Description: PGP signature

reply via email to

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