Fix compile warning on FreeBSD (bug #1755)