On Fri, Jan 11, 2013 at 6:24 AM, Mauro Faccenda <facce...@gmail.com> wrote: > #include <stdio.h> > int > EFIAPI > main ( > IN int Argc, > IN char **Argv > ) > { > printf("\nArgc=%d\n", Argc); > return 0; > } > -- > And whenever I run it on UEFI Shell (using qemu), I always get really > big values (> 37000000) no matter with how many parameter I run and if > I run with the same parameter multiple times, the value sometimes > changes, as you can see on the image below:
Looking in StdLib/LibC/Main/Main.c, it seems that main is prototyped as: extern int main( int, char**); Notice the lack of EFIAPI. Perhaps you can try to remove that and see if argc prints out properly? I notice that AppPkg/Applications/Main/Main.c also has EFIAPI. I'm not sure, but I think it should be removed from there. -Jordan ------------------------------------------------------------------------------ Master Visual Studio, SharePoint, SQL, ASP.NET, C# 2012, HTML5, CSS, MVC, Windows 8 Apps, JavaScript and much more. Keep your skills current with LearnDevNow - 3,200 step-by-step video tutorials by Microsoft MVPs and experts. SALE $99.99 this month only -- learn more at: http://p.sf.net/sfu/learnmore_122912 _______________________________________________ edk2-devel mailing list edk2-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/edk2-devel