[FFmpeg-cvslog] r10732 - trunk/libavutil/rc4.h

Aurelien Jacobs aurel
Sun Oct 14 23:30:23 CEST 2007


Diego Biurrun wrote:

> On Sun, Oct 14, 2007 at 02:50:40PM +0200, Aurelien Jacobs wrote:
> > On Sun, 14 Oct 2007 11:51:39 +0200 (CEST)
> > diego <subversion at mplayerhq.hu> wrote:
> > 
> > > Log:
> > > Add multiple inclusion guards.
> > > 
> > > --- trunk/libavutil/rc4.h	(original)
> > > +++ trunk/libavutil/rc4.h	Sun Oct 14 11:51:38 2007
> > > @@ -18,4 +18,9 @@
> > >   * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
> > >   */
> > >  
> > > +#ifndef RC4_H
> > > +#ifndef RC4_H
> > 
> > RC4_H seems quite generic, and might easily clash with another
> > header. Using AVUTIL_RC4_H would be safer IMO. And I think that's
> > the convention that was agreed some times ago.
> 
> Yes, I was looking into this as well while committing this change.  In
> libavutil we have some multiple inclusion guards with AVUTIL prefix,
> some with AV prefix and some without prefix.  I don't think we agreed to
> any convention in the past, but I absolutely share the opinion that it
> would be useful.

IIRC, it was Mans who some times ago added a bunch of multiple inclusion
guards, all with the AVCODEC_ prefix (correct me if I'm wrong).

> I'm willing to go forward and update the multiple inclusion guards in
> all header files if we can agree on a standard format.  I propose
> AVUTIL_, AVCODEC_, AVFORMAT_, POSTPROC_, SWSCALE_ and maybe FFMPEG_ for
> the header files in the top-level directory.

Absolutely agree.

Aurel




More information about the ffmpeg-cvslog mailing list