Path: utzoo!utgpu!news-server.csri.toronto.edu!bonnie.concordia.ca!uunet!spool2.mu.edu!think.com!hsdndev!dartvax!baker.dartmouth.edu!jenny From: jenny@baker.dartmouth.edu (Jennifer Merrill) Newsgroups: comp.unix.ultrix Subject: Re: problem with gethostname() under 4.1 Message-ID: <1991Jan28.192827.6499@dartvax.dartmouth.edu> Date: 28 Jan 91 19:28:27 GMT References: <40589@ucbvax.BERKELEY.EDU> <1991Jan26.021822.28952@pa.dec.com> Sender: news@dartvax.dartmouth.edu (The News Manager) Organization: Dartmouth College, Hanover, NH Lines: 27 No doubt you are going to think this is crazy, but we had the same problem when we moved or code from a Vax running 4.3BSD to a 5810 running Ultrix 3.? (I can't remember which). It turned out, in our case, that the problem was conflicting variables. I had a program with a global array called 'databases'. I eventually found out that the routine getsvc also has a variable called 'databases'. (I found this by doing a nm(1) on libc.a.) As I filled in my array, I trashed the getsvc's version of databases and eventually that system call failed. I'm not familiar with the program nfswatch, but my suggestion would be to do an nm on the binary and see if you find any conflicts. Find out what variables are used by gethostname (and the routines it calls) and then see if you've got any of those in nfswatch. Good luck!! --- Jennifer K. Merrill (Jennifer.Merrill@dartmouth.edu) Library Computing Services Dartmouth College -- --- Jennifer K. Merrill (Jennifer.Merrill@dartmouth.edu) Library Computing Services Dartmouth College