From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,16b5f96c922749ee X-Google-Attributes: gid103376,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news2.google.com!postnews.google.com!a8g2000prf.googlegroups.com!not-for-mail From: Adam Beneschan Newsgroups: comp.lang.ada Subject: Re: Command Line on windows Date: Fri, 12 Sep 2008 08:27:54 -0700 (PDT) Organization: http://groups.google.com Message-ID: <59bfa027-9360-4e60-a46a-346c1acb36f9@a8g2000prf.googlegroups.com> References: <9516d238-9e52-4de4-9993-590472a1ffba@w7g2000hsa.googlegroups.com> <3Lvyk.339291$yE1.317044@attbi_s21> NNTP-Posting-Host: 66.126.103.122 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Trace: posting.google.com 1221233274 1249 127.0.0.1 (12 Sep 2008 15:27:54 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Fri, 12 Sep 2008 15:27:54 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: a8g2000prf.googlegroups.com; posting-host=66.126.103.122; posting-account=duW0ogkAAABjRdnxgLGXDfna0Gc6XqmQ User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.7.12) Gecko/20050922 Fedora/1.7.12-1.3.1,gzip(gfe),gzip(gfe) Xref: g2news1.google.com comp.lang.ada:2001 Date: 2008-09-12T08:27:54-07:00 List-Id: On Sep 12, 8:18 am, "Jeffrey R. Carter" wrote: > RasikaSriniva...@gmail.com wrote: > > > but it appears the wildcard is always "expanded to the list of file > > names". for example, i create test_cli.adb with the following : > > This appears to be a "feature" of GNAT, apparently to make programs behave the > same on Windows as on Linux, where wildcards are expanded by the shell. You can get around this by calling GetCommandLine yourself; this will get Windows to give you the original command line, unprocessed by GNAT. See http://msdn.microsoft.com/en-us/library/ms683156(VS.85).aspx But you'll have to deal with the null terminator yourself (Interfaces.C.Strings should help here) and parse the arguments yourself. -- Adam