Merge shurd patch at https://bugs.freebsd.org/bugzilla/attachment.cgi?id=144778&action=edit