On Thu, Feb 20, 2020 at 12:12:58PM -0800, Junio C Hamano wrote: > Emily Shaffer <emilyshaffer@xxxxxxxxxx> writes: > > > + /* system call for other version info */ > > + strbuf_addstr(sys_info, "uname -a: "); > > Is that "-a" portable across systems? That is, when given "-a", > would "uname" on all platforms show sysname, release, version and > machine in that order and nothing else? > > If we are merely saying "in this section, we are showing a selected > subset from what we learned about the system with uname(2)", perhaps > just stop at saying "uname: "? Sure, that's good enough for me. I think actually 'uname -a' on a GNU system isn't going to match what's output here anyways, since I don't show the nodename and 'uname -a' would. > > > + if (uname(&uname_info)) > > + strbuf_addf(sys_info, "uname() failed with code %d\n", errno); > > i18n/l10n? Don't we want to use strerror() here? Much much earlier[1] in the series, you suggested not i18n/l10n the contents of the bugreport, as this list would probably be ill-equipped to process such a report. Since it's being added to sys_info, that means this line is bound for the finished report, not for the user. Speaking of locale, strerror() will print the error in the current locale; if we're still assuming "the list only takes reports in English" should I be explicit and use strerror_l()? Should I print strerror() in current locale and include the errno, e.g. ("uname() failed with '%s' (%d)\n", strerror(errno), errno)? [1] https://lore.kernel.org/git/xmqqzhka2tbv.fsf@xxxxxxxxxxxxxxxxxxxxxxxxx