This is the mail archive of the mailing list for the glibc project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: What does LAV_CURRENT mean backwards compatibility of LD_AUDIT interface?

On 02/26/2015 07:38 PM, Carlos O'Donell wrote:
> (a) Version N+1 is backwards compatible.
> In this scenario we are constrained by previous implementations
> and are forced to make only backwards compatible changes.
> This means that for an application to see a version in la_version
> greater than the version it expects is OK, since everything is
> backwards compatible.
> Code like we have in elf/sotruss-lib.c would then be a bad exmaple
> of how to do things. e.g.
> 121 /* Audit interface verification.  We also initialize everything if
> 122    everything checks out OK.  */
> 123 unsigned int
> 124 la_version (unsigned int v)
> 125 {
> 126   if (v != LAV_CURRENT)
> 127     error (1, 0, "cannot handle interface version %u", v);
> 128 
> 129   init ();
> 130 
> 131   return v;
> 132 }
> Should instead check for `v < LAV_CURRENT` before issuing an error.
> I know that we do this today because sotruss-lib should match the
> library, but users might cut-and-paste some of this code and it should
> showcase best practice or have a comment that talks about it.

I'm going to just come out and say that glibc is a conservative project
and that any LD_AUDIT changes are always backwards compatible.

This means the official stance I'd like to take is that if the incoming
value of version is > LAV_CURRENT that you have all the support you need.

Flag bits will be allocated and if we run out we run out.

Backwards compatibility will be the guiding principle.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]