delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2000/03/24/14:42:49

From: Ian Chapman <ichapman AT nortelnetworks DOT com>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: need help
Date: Fri, 24 Mar 2000 13:26:24 -0500
Organization: Nortel
Lines: 28
Message-ID: <38DBB34F.D2F1F696@nortelnetworks.com>
References: <38ce5d23$0$28656 AT SSP1NO17 DOT highway DOT telekom DOT at>
NNTP-Posting-Host: bcarib90.ca.nortel.com
Mime-Version: 1.0
X-Mailer: Mozilla 4.7 [en] (Win95; U)
X-Accept-Language: en
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

Hi Florian,
	the variable close_if_finished is not defined.  Is it integer?  For
your code to work must be a global variable.

//	Florian's code
int close_if_finished;
int main()
{
finished();
}


> void finished()
> {
>               if (close_if_finished == true)
>                  {
>                  close_if_finished = false;
>                  }
>               else
>                  {
>                  close_if_finished = true;
>                   }
> }
	If  close if finished is defined in some other function it is out of
scope in finished().  You must pass it to finished as a parameter, this
is the prefered way.

		Regards Ian.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019