Use POSIX functions to get program name and max host length