Re: [PATCH v4 03/15] bugreport: gather git version and build info

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Johannes Schindelin <Johannes.Schindelin@xxxxxx> writes:

>> +	if (build_options) {
>> +		strbuf_addf(buf, "cpu: %s\n", GIT_HOST_CPU);
>> +		if (git_built_from_commit_string[0])
>> +			strbuf_addf(buf, "built from commit: %s\n",
>> +			       git_built_from_commit_string);
>> +		else
>> +			strbuf_addf(buf, "no commit associated with this build\n");
>
> The "StaticAnalysis" job of the Azure Pipeline is not happy with this,
> claiming that this should be an `strbuf_addstr()` call instead.

You mean the "else" clause, right?  That feels similar to say

	printf("Hello world\n");

should better be written as

	fputs("Hello world\n", stdout);

which I do not agree with at all.  IOW, I view the distinction more
like "once it is written one way or the other way, it is not worth
spending bits and braincycles to see if it is worth changing it"
kind of minor stylistic preference.





[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux