So I had another look at this, and realised that the patch looks pretty ugly, being all interleaved with the FreeBSD code... Here's another patch, that just adds a new section for Darwin. I feel much better about it now. Any thoughts or objections? Regards, Magnus