Re: [PATCH] Trivial warning fix for imap-send.c
- From
- Mark Wooding <mdw@distorted.org.uk>
- Date
- Mar 12, 2006, 10:44 UTC
- Message-ID
- <slrne17urp.fr9.mdw@metalzone.distorted.org.uk>
- In-Reply-To
- <20060311192954.GQ16135@artsapartment.org>
"Art Haas" <ahaas@airmail.net> wrote:
Show 10 quoted lines
> --- a/imap-send.c > +++ b/imap-send.c > @@ -945,7 +945,7 @@ imap_open_store( imap_server_conf_t *srv > _exit( 127 ); > close( a[0] ); > close( a[1] ); > - execl( "/bin/sh", "sh", "-c", srvc->tunnel, 0 ); > + execl( "/bin/sh", "sh", "-c", srvc->tunnel, NULL ); > _exit( 127 ); > }
This is not the right fix. NULL can be simply a #define for 0 (see 6.3.2.3#3 and 7.17). You need to write (char *)0 or (char *)NULL. I prefer to avoid the macro NULL entirely, since its misleading behaviour is precisely what got us into this mess.
-- [mdw]