[FFmpeg-devel] _t POSIX namespace issues

Aurelien Jacobs aurel
Sun Dec 14 01:11:31 CET 2008


On Sat, 13 Dec 2008 14:12:57 +0100
Diego Biurrun <diego at biurrun.de> wrote:

> On Thu, Dec 11, 2008 at 09:31:43AM +0100, Diego Biurrun wrote:
> > So names ending in _t are reserved by POSIX.  Nonetheless we have tons
> > of them.  I thought about fixing these issues myself, but coming up with
> > good new names is tedious, so I propose to have each maintainer address
> > the problem in the files they maintain.  Here is a the result of a grep
> > for problematic names with maintainers, in no particular order:
> > 
> > unmaintained:
> > libavcodec/indeo3.c:} ustr_t;
> 
> Patch attached.
> 
> [...]
> 
> @@ -252,14 +252,14 @@
>  
>          if(cmd == 0) {
>              strip++;
> -            memcpy(strip, strip-1, sizeof(ustr_t));
> +            memcpy(strip, strip-1, sizeof(struct ustr));

sizeof(*strip) would be even better...

>          } else if(cmd == 1) {
>              strip++;
> -            memcpy(strip, strip-1, sizeof(ustr_t));
> +            memcpy(strip, strip-1, sizeof(struct ustr));

Same here.

Aurel




More information about the ffmpeg-devel mailing list