Fixed errors when building under SunOS 5.11 (Solaris) with gcc