[OpenAFS-devel] Aliasing bugs

Garrett Wollman wollman@csail.mit.edu
Tue, 12 Jul 2011 19:14:32 -0400


<<On Tue, 12 Jul 2011 18:31:40 -0400 (EDT), Benjamin Kaduk <kaduk@MIT.EDU> said:

> A few of the errors are more structural in nature, e.g. the "unique 
> identifier" for the vop_advlock routines that always has a 32-bit field 
> but sometimes tries to squash a 64-bit value into it.

I looked at that as well.  That VOP_ADVLOCK argument was apparently a
pid_t on some system, but now it is multiple different kinds of
pointer -- it can be a pointer to at least a struct proc or a struct
file, depending on the kind of lock it is.  (POSIX specifies stupid
semantics for what happens to locks when a file is closed, which I
think accounts for some of the weirdness.)

I was going to see about making it an intptr_t, but it looked like a
bit of a slog so I put off thinking about it any further.

-GAWollman