LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 05-08-2006, 07:22 PM   #1
schanuzie
LQ Newbie
 
Registered: May 2006
Posts: 1

Rep: Reputation: 0
Question Problems with putenv and getenv


Hi I am a newbie in Linux and encountered a problem with putenv and getenv while using Linux. I did not see this issue with VxWorks so I am assuming that this may be related to processes.

In my code I have a powerup() function where I call another function get_ips()to perform a putenv. After that I call another function set_ips() where I perform a getenv to save the ip in a string so that I can setup a socket. Now when I do a putenv I can see that the environment variable is set, but when I do a getenv the environment variable is no longer set. I thought that it was due to different processes so I put in logMsgs where I did the put/getenv but the logMsgs are telling me that they are running of the same task - main. Can anyone help me understand why this is happening? Am I on the right path? Thank you for your help in advance.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Marvell Yukon Network driver problems, Lilo Windows boot Problems mellowdog Slackware - Installation 7 01-25-2006 03:18 AM
Apache getenv bug? wu1821 Linux - General 1 06-29-2005 11:00 AM
Ethernet Adsl Modem Driver Problems And Install Problems... akhilnair Linux - Hardware 12 11-28-2004 09:19 AM
Problems, problems, problems. Lets start with the soundcard Kre8ive Linux - Newbie 5 08-07-2003 02:20 AM
Problems, problems, problems. Lets start with the ES 1868 AudioDrive Kre8ive Linux - Newbie 1 08-06-2003 08:04 PM


All times are GMT -5. The time now is 03:11 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration