Fixed null ptr dereference on solaris when getexecname fails