Adam: If you want your code to be file system, AFS client, and version independent you really need to test the functionality and and not the implementations. Specifically, you must perform a test that attempts to lock a byte range, spin off a second process attempt to lock the same byte range, and test for the failure. If the failure doesn't occur, then you know you need to fall back on a locking strategy that doesn't rely on byte range locks.
There is no guarantee that any two AFS clients are going to use the same pioctl mechanism. Nor can you count on the fsinfo.f_type to be anything other than 0 for AFS because all of the existing clients have published 0. Nor can you count on any particular AFS client to support byte range locking. At the moment, only the Windows client supports byte range locking. Work was being done for the UNIX client but it stalled when the developer became more interested in other projects. I would focus on completely independent tests. Jeffrey Altman
smime.p7s
Description: S/MIME Cryptographic Signature
