fixes to make it work under Ultrix