This patch (updated to be applied today) was sent via Jira by royj@yandex.ru, with Jira issue FS-4338.

Apply in this way:
# patch -p6 < FREEBSD_patch.diff

I have not tested it, but it works for him.
Please open another Jira issue if anything wrong.

-giovanni
