home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.c
- Path: sparky!uunet!zaphod.mps.ohio-state.edu!cs.utexas.edu!asuvax!ncar!news.miami.edu!aem
- From: aem@news.miami.edu (andrew mossberg)
- Subject: putenv question
- Message-ID: <1992Nov23.204330.13594@news.miami.edu>
- Organization: R.S.M.A.S.
- Distribution: na
- Date: Mon, 23 Nov 92 20:43:30 GMT
- Lines: 15
-
-
- I'm trying to read a file and place lines found there into the environment
- via putenv, but it isn't cooperating. It works fine when I hardcode
- values into the putenv calls, like putenv("SSS=adas");, but reading
- a file using fgets() and then putenv'ing the line (sans trailing newline)
- only leave the last line in the environment. Obviously I'm doing something
- wrong with pointers, but I can't figure out what. Please, someone, tell
- me what idiotic mistake I'm making this time! This is on a HP 9000/720
- running HP/UX 8.0.7
-
- aem
-
- --
- a.e.mossberg Symbiosis Corporation Miami, Florida aem@symbiosis.ahp.com
- (305) 597-4110 fax: (305) 597-4002 alt mailbox: aem@umigw.miami.edu
-