Article View: alt.folklore.computers
Article #623220Re: Tahoe and Alpha Architectures
From: Robert Munyer
Date: Mon, 30 Apr 2018 23:26
Date: Mon, 30 Apr 2018 23:26
51 lines
3268 bytes
3268 bytes
Scott Lurndal wrote:
> d...@ihatespam.msu.edu (Dennis Boone) writes:
>> Skipping over the people that don't use bash, and the scripts that
>> use /bin/true rather than the builtin, ...
>>
>> int
>> main (int argc, char **argv)
>> {
>> /* Recognize --help or --version only if it's the only command-line
>> argument. */
>> if (argc == 2)
>> {
>> initialize_main (&argc, &argv);
>> set_program_name (argv[0]);
>> setlocale (LC_ALL, "");
>> bindtextdomain (PACKAGE, LOCALEDIR);
>> textdomain (PACKAGE);
>>
>> /* Note true(1) will return EXIT_FAILURE in the
>> edge case where writes fail with GNU specific options. */
>> atexit (close_stdout);
>>
>> if (STREQ (argv[1], "--help"))
>> usage (EXIT_STATUS);
>>
>> if (STREQ (argv[1], "--version"))
>> version_etc (stdout, PROGRAM_NAME, PACKAGE_NAME, Version, AUTHORS,
>> (char *) NULL);
>> }
>>
>> return EXIT_STATUS;
>> }
>
> not on fedora:
>
> $ ltrace true
> __libc_start_main(0x401260, 1, 0x7fff32d19f28, 0x403420, 0x403410 <unfinished ...>
> exit(0 <unfinished ...>
> +++ exited (status 0) +++
>
>
> Note the lack of a setlocale() call.
I think your test case activated the wrong execution path, causing
setlocale to be absent from the trace even if your executable file
had been compiled from the exact source code that Dennis posted.
--
e-mail: the TLD is COM, the subdomain is my surname,
and the local-part is the product of 191773 and 48271.
Technical Details
Message-ID:
<pc88mv$1j13$1@gioia.aioe.org>Path:
mbox-mo1.pugleaf.net!c8-v6ni573qtc.0!nntp.google.com!peer02.iad!feed-me.highwinds-media.com!peer01.am4!peer.am4.highwinds-media.com!news.highwinds-media.com!newsfeed.xs4all.nl!newsfeed9.news.xs4all.nl!news.redatomik.org!aioe.org!.POSTED!not-for-mailReferences:
<pbo1cs$ku4$1@dont-email.me> <aba6f057-18a5-4eb8-9dff-d3a5d1665be1@googlegroups.com> <pbot0l$6co$2@tncsrv09.home.tnetconsulting.net> <32fc945c-cfcd-4598-926f-abe202a137a4@googlegroups.com> <pbsm9u$bb9$1@dont-email.me> <bbp4ed1n658k2p7u6alhdg1rnoivrhfm8n@4ax.com> <20180427075311.a4996754bddb0b48978021c7@eircom.net> <yfmdnc653fDZrn7HnZ2dnUU7-b2dnZ2d@giganews.com> <pbvcnq$iau$1@dont-email.me> <vIudnTk13ozcaX7HnZ2dnUU7-XmdnZ2d@giganews.com> <%c0FC.31957$LR2.28175@fx41.iad>Show Full Headers
Complete Article Headers
X-Received: by 2002:ac8:548:: with SMTP id c8-v6mr9133151qth.14.1525130798937; Mon, 30 Apr 2018 16:26:38 -0700 (PDT) X-BeenThere: alt.folklore.computers@googlegroups.com Received: by 2002:a0c:8a1c:: with SMTP id 28-v6ls2679138qvt.10.gmail; Mon, 30 Apr 2018 16:26:38 -0700 (PDT) X-Received: by 2002:a0c:e9c6:: with SMTP id q6-v6mr8680139qvo.31.1525130798240; Mon, 30 Apr 2018 16:26:38 -0700 (PDT) MIME-Version: 1.0 Path: mbox-mo1.pugleaf.net!c8-v6ni573qtc.0!nntp.google.com!peer02.iad!feed-me.highwinds-media.com!peer01.am4!peer.am4.highwinds-media.com!news.highwinds-media.com!newsfeed.xs4all.nl!newsfeed9.news.xs4all.nl!news.redatomik.org!aioe.org!.POSTED!not-for-mail From: Robert Munyer <robertm@not-for-mail.invalid> Newsgroups: alt.folklore.computers Subject: Re: Tahoe and Alpha Architectures Date: Mon, 30 Apr 2018 23:26:35 +0000 (UTC) Organization: Aioe.org NNTP Server Lines: 51 Message-ID: <pc88mv$1j13$1@gioia.aioe.org> References: <pbo1cs$ku4$1@dont-email.me> <aba6f057-18a5-4eb8-9dff-d3a5d1665be1@googlegroups.com> <pbot0l$6co$2@tncsrv09.home.tnetconsulting.net> <32fc945c-cfcd-4598-926f-abe202a137a4@googlegroups.com> <pbsm9u$bb9$1@dont-email.me> <bbp4ed1n658k2p7u6alhdg1rnoivrhfm8n@4ax.com> <20180427075311.a4996754bddb0b48978021c7@eircom.net> <yfmdnc653fDZrn7HnZ2dnUU7-b2dnZ2d@giganews.com> <pbvcnq$iau$1@dont-email.me> <vIudnTk13ozcaX7HnZ2dnUU7-XmdnZ2d@giganews.com> <%c0FC.31957$LR2.28175@fx41.iad> NNTP-Posting-Host: rEuLJGYHN3ivvEZMZWpmJw.user.gioia.aioe.org X-Complaints-To: ab...@aioe.org X-Notice: Filtered by postfilter v. 0.8.3 X-Received-Bytes: 2706 X-Received-Body-CRC: 3225443126 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit