Re: CLIL source code from book "Firmware demystified"
- From: "Jet Morgan" <jm@xxxxxxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Thu, 30 Jun 2005 10:55:28 +0100
"Roman Mashak" <mrv@xxxxxxxx> wrote in message
news:d9vfh0$2uir$1@xxxxxxxxxxxxxxxxx
> EMG> int valid_options(int argc, char *argv[], )
> I don't quite understand WHY I can pass 'argc' and 'argv' to another
> function? The reason I ask this is every command I type in command line is
> not a seperate process, it's run in the whoel scope (according to the book
I
> mentioned before). And originally 'argc' and 'argv' are valid for
> single-running processes, not as a part of any code.
I don't understand your non-understanding. argc and argv have lifetime
throughout the execution of the process in question. The first is
an integer, and the second is a pointer to a (effectively constant)
array of strings. If you need to be able to use these anywhere in your
code (for a single process) you can. What is it that you expect not
to be able to do ?
In particular, what do you mean by "single-running processes, not as
a part of any code" ?
Richard [in PE12]
.
- References:
- CLIL source code from book "Firmware demystified"
- From: Roman Mashak
- Re: CLIL source code from book "Firmware demystified"
- From: Lanarcam
- Re: CLIL source code from book "Firmware demystified"
- From: Roman Mashak
- Re: CLIL source code from book "Firmware demystified"
- From: Everett M. Greene
- Re: CLIL source code from book "Firmware demystified"
- From: Roman Mashak
- CLIL source code from book "Firmware demystified"
- Prev by Date: Re: PCI interface/protocol chips
- Next by Date: Re: Selection of a microcontroller for Childs Toy...
- Previous by thread: Re: CLIL source code from book "Firmware demystified"
- Next by thread: Re: CLIL source code from book "Firmware demystified"
- Index(es):
Relevant Pages
|