[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
test build of 4.9 started
- Date: Tue, 10 Mar 2009 00:43:45 -0400
- From: feng at bnl.gov (Feng, Kate)
- Subject: test build of 4.9 started
The "Hello, world example shows:
The footnotes 10 states :
"The main function actually has two arguments, int argc and char *argv, respectively, which can be used to handle command line arguments <http://en.wikipedia.org/wiki/Command_line_arguments> . The C standard requires that both forms of main be supported, which is special treatment not afforded any other function."
Thus, the information I have did not mention that main function has three arguements.
However, it's true that main() can afford sepcial treament as long as it is defined consistently
throughout the code. I am not aware that it broke any code. It was just my concern about
being consistent. I agree it's better to follow the C99 standard. It seems that C99 follows
C standard for the main() function.
From: Joel Sherrill [mailto:joel.sherrill at oarcorp.com]
Sent: Mon 3/9/2009 3:02 PM
To: Kate Feng
Cc: RTEMS Users
Subject: Re: test build of 4.9 started
Kate Feng wrote:
> Please never mind. I just realized that RTEMS main() is
> indeed defined as
> int main(int argc, char **argv, char **environp)
> instead of the usual
> int main( int, char **);
It would be better to match C99 though if we can
get a definitive answer.
> Kate Feng wrote:
>> Joel Sherrill wrote:
>>> I just started a test build of the 4.9 branch.
>>> If all goes well, I will cut 4.9.2 once it is
>>> pr1385 will be closed. I am building with
>>> the latest patch.
>>> If you have an outstanding issue, yell now.
>> In cpukit/libmisc/dummy/dummy.c, should
>> "int main( int, char **, char **); "
>> be corrected as
>> "int main( int, char **);"
>> Is there a conflict ?
>> rtems-users mailing list
>> rtems-users at rtems.com
Joel Sherrill, Ph.D. Director of Research & Development
joel.sherrill at OARcorp.com On-Line Applications Research
Ask me about RTEMS: a free RTOS Huntsville AL 35805
Support Available (256) 722-9985