{"thread":{"id":"58596","subject":"What's cooking in git.git (Oct 2022, #03; Mon, 10)","startedAt":"2022-10-10T23:37:36Z","lastAt":"2022-12-22T17:40:20Z","messageCount":8,"participants":["Junio C Hamano","Jeff King","Johannes Schindelin","Ævar Arnfjörð Bjarmason"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"464544","messageId":"xmqqlepnz1vu.fsf@gitster.g","threadId":"58596","inReplyTo":null,"subject":"What's cooking in git.git (Oct 2022, #03; Mon, 10)","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2022-10-10T23:37:25Z","receivedAt":"2022-10-10T23:37:36Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Here are the topics that have been cooking in my tree.  Commits\nprefixed with '+' are in 'next' (being in 'next' is a sign that a\ntopic is stable enough to be used and are candidate to be in a future\nrelease).  Commits prefixed with '-' are only in 'seen', and aren't\nconsidered \"accepted\" at all.  A topic without enough support may be\ndiscarded after a long period of no activity.\n\nSome topics have been expecting updates for too long.  Before, or\nsoon after, rewinding the 'next' branch and opening the floodgates\nfor this cycle, we may want to discard them, unless they see some\nactivities.\n\nCopies of the source code to Git live in many repositories, and the\nfollowing is a list of the ones I push into or their mirrors.  Some\nrepositories have only a subset of branches.\n\nWith maint, master, next, seen, todo:\n\n\tgit://git.kernel.org/pub/scm/git/git.git/\n\tgit://repo.or.cz/alt-git.git/\n\thttps://kernel.googlesource.com/pub/scm/git/git/\n\thttps://github.com/git/git/\n\thttps://gitlab.com/git-vcs/git/\n\nWith all the integration branches and topics broken out:\n\n\thttps://github.com/gitster/git/\n\nEven though the preformatted documentation in HTML and man format\nare not sources, they are published in these repositories for\nconvenience (replace \"htmldocs\" with \"manpages\" for the manual\npages):\n\n\tgit://git.kernel.org/pub/scm/git/git-htmldocs.git/\n\thttps://github.com/gitster/git-htmldocs.git/\n\nRelease tarballs are available at:\n\n\thttps://www.kernel.org/pub/software/scm/git/\n\n--------------------------------------------------\n[Graduated to 'master']\n\n* ab/test-malloc-with-sanitize-leak (2022-09-29) 1 commit\n  (merged to 'next' on 2022-09-29 at b6fef2dd1f)\n + test-lib: have SANITIZE=leak imply TEST_NO_MALLOC_CHECK\n\n Test fix.\n source: <patch-1.1-e31681731b7-20220928T095041Z-avarab@gmail.com>\n\n\n* ac/fuzzers (2022-09-19) 1 commit\n  (merged to 'next' on 2022-09-29 at 600f45a53b)\n + fuzz: reorganise the path for existing oss-fuzz fuzzers\n\n Source file shuffling.\n source: <pull.1353.v4.git.1663598215154.gitgitgadget@gmail.com>\n\n\n* ah/branch-autosetupmerge-grammofix (2022-09-28) 1 commit\n  (merged to 'next' on 2022-09-29 at 622b75f0da)\n + push: improve grammar of branch.autoSetupMerge advice\n\n Fix grammar of a message introduced in previous round.\n source: <20220928055811.777227-1-alexhenrie24@gmail.com>\n\n\n* ah/fsmonitor-daemon-usage-non-l10n (2022-09-21) 1 commit\n  (merged to 'next' on 2022-09-21 at bc69a73c6c)\n + fsmonitor--daemon: don't translate literal commands\n\n Fix messages incorrectly marked for translation.\n source: <20220920050709.326359-1-alexhenrie24@gmail.com>\n\n\n* dd/retire-efgrep (2022-09-21) 4 commits\n  (merged to 'next' on 2022-09-21 at 22bc339be1)\n + t: convert fgrep usage to \"grep -F\"\n + t: convert egrep usage to \"grep -E\"\n + t: remove \\{m,n\\} from BRE grep usage\n + CodingGuidelines: allow grep -E\n (this branch is used by es/retire-efgrep.)\n\n Prepare for GNU [ef]grep that throw warning of their uses.\n source: <cover.1663765176.git.congdanhqx@gmail.com>\n\n\n* ds/scalar-unregister-idempotent (2022-09-27) 4 commits\n  (merged to 'next' on 2022-09-28 at a09a78d861)\n + string-list: document iterator behavior on NULL input\n + gc: replace config subprocesses with API calls\n + scalar: make 'unregister' idempotent\n + maintenance: add 'unregister --force'\n\n \"scalar unregister\" in a repository that is already been\n unregistered reported an error.\n source: <pull.1358.v4.git.1664287021.gitgitgadget@gmail.com>\n\n\n* ds/use-platform-regex-on-macos (2022-08-26) 1 commit\n  (merged to 'next' on 2022-09-14 at 80905596d8)\n + grep: fix multibyte regex handling under macOS\n\n With a bit of header twiddling, use the native regexp library on\n macOS instead of the compat/ one.\n source: <20220826085815.2771102-1-dds@aueb.gr>\n\n\n* es/retire-efgrep (2022-09-23) 2 commits\n  (merged to 'next' on 2022-09-27 at 344fdd138e)\n + check-non-portable-shell: detect obsolescent egrep/fgrep\n + Merge branch 'dd/retire-efgrep' into es/retire-efgrep\n (this branch uses dd/retire-efgrep.)\n\n Prepare for GNU [ef]grep that throw warning of their uses.\n source: <pull.1338.git.git.1663805905554.gitgitgadget@gmail.com>\n\n\n* hn/parse-worktree-ref (2022-09-19) 1 commit\n  (merged to 'next' on 2022-09-29 at 1f4453eb83)\n + refs: unify parse_worktree_ref() and ref_type()\n\n Code and semantics cleaning.\n source: <pull.1325.v2.git.git.1663605291172.gitgitgadget@gmail.com>\n\n\n* ja/rebase-i-avoid-amending-self (2022-09-26) 1 commit\n  (merged to 'next' on 2022-09-29 at 2635f37dae)\n + sequencer: avoid dropping fixup commit that targets self via commit-ish\n\n \"git rebase -i\" can mistakenly attempt to apply a fixup to a commit\n itself, which has been corrected.\n source: <20220924222904.1784975-1-aclopte@gmail.com>\n\n\n* jc/environ-docs (2022-09-16) 5 commits\n  (merged to 'next' on 2022-09-29 at a0a43b8de5)\n + environ: GIT_INDEX_VERSION affects not just a new repository\n + environ: simplify description of GIT_INDEX_FILE\n + environ: GIT_FLUSH should be made a usual Boolean\n + environ: explain Boolean environment variables\n + environ: document GIT_SSL_NO_VERIFY\n\n Documentation on various Boolean GIT_* environment variables have\n been clarified.\n source: <20220915160659.126441-1-gitster@pobox.com>\n\n\n* jk/clone-allow-bare-and-o-together (2022-09-22) 1 commit\n  (merged to 'next' on 2022-09-27 at 1feca721ac)\n + clone: allow \"--bare\" with \"-o\"\n\n \"git clone\" did not like to see the \"--bare\" and the \"--origin\"\n options used together without a good reason.\n source: <YyvzVdfQVdysvMp2@coredump.intra.peff.net>\n\n\n* jk/fsck-on-diet (2022-09-22) 3 commits\n  (merged to 'next' on 2022-09-27 at c2e93082a1)\n + parse_object_buffer(): respect save_commit_buffer\n + fsck: turn off save_commit_buffer\n + fsck: free tree buffers after walking unreachable objects\n\n \"git fsck\" failed to release contents of tree objects already used\n from the memory, which has been fixed.\n source: <Yyw0PSVe3YTQGgRS@coredump.intra.peff.net>\n\n\n* jk/remote-rename-without-fetch-refspec (2022-09-22) 1 commit\n  (merged to 'next' on 2022-09-27 at 165fe0a832)\n + remote: handle rename of remote without fetch refspec\n\n \"git remote rename\" failed to rename a remote without fetch\n refspec, which has been corrected.\n source: <YyvzqZ5tmI0UdRAW@coredump.intra.peff.net>\n\n\n* js/merge-ort-in-read-only-repo (2022-09-28) 2 commits\n  (merged to 'next' on 2022-09-29 at 84df46c1b4)\n + merge-ort: return early when failing to write a blob\n + merge-ort: fix segmentation fault in read-only repositories\n\n In read-only repositories, \"git merge-tree\" tried to come up with a\n merge result tree object, which it failed (which is not wrong) and\n led to a segfault (which is bad), which has been corrected.\n source: <pull.1362.v5.git.1664350162.gitgitgadget@gmail.com>\n\n\n* mc/cred-helper-ignore-unknown (2022-09-22) 3 commits\n  (merged to 'next' on 2022-09-27 at ce6e3616aa)\n + osxkeychain: clarify that we ignore unknown lines\n + netrc: ignore unknown lines (do not die)\n + wincred: ignore unknown lines (do not die)\n\n Most credential helpers ignored unknown entries in a credential\n description, but a few died upon seeing them.  The latter were\n taught to ignore them, too\n source: <pull.1363.git.1663865974.gitgitgadget@gmail.com>\n\n\n* rj/ref-filter-get-head-description-leakfix (2022-09-26) 1 commit\n  (merged to 'next' on 2022-09-29 at d05d052eb1)\n + ref-filter.c: fix a leak in get_head_description\n\n Leakfix.\n source: <6ff29e96-7f8d-c354-dced-b1b363e54467@gmail.com>\n\n\n* so/diff-merges-cleanup (2022-09-16) 3 commits\n  (merged to 'next' on 2022-09-22 at 57694bbed7)\n + diff-merges: clarify log.diffMerges documentation\n + diff-merges: cleanup set_diff_merges()\n + diff-merges: cleanup func_by_opt()\n\n Code clean-up.\n source: <20220914193102.5275-1-sorganov@gmail.com>\n\n\n* sy/sparse-grep (2022-09-23) 1 commit\n  (merged to 'next' on 2022-09-29 at a5bc34b9c5)\n + builtin/grep.c: integrate with sparse index\n\n \"git grep\" learned to expand the sparse-index more lazily and on\n demand in a sparse checkout.\n source: <20220923041842.27817-2-shaoxuan.yuan02@gmail.com>\n\n\n* tb/midx-repack-ignore-cruft-packs (2022-09-21) 7 commits\n  (merged to 'next' on 2022-09-29 at 55474c6ecc)\n + midx.c: avoid cruft packs with non-zero `repack --batch-size`\n + midx.c: remove unnecessary loop condition\n + midx.c: replace `xcalloc()` with `CALLOC_ARRAY()`\n + midx.c: avoid cruft packs with `repack --batch-size=0`\n + midx.c: prevent `expire` from removing the cruft pack\n + Documentation/git-multi-pack-index.txt: clarify expire behavior\n + Documentation/git-multi-pack-index.txt: fix typo\n\n \"git multi-pack-index repack/expire\" used to repack unreachable\n cruft into a new pack, which have been corrected.\n cf. <63a1c3d4-eff3-af10-4263-058c88e74594@github.com>\n source: <cover.1663638929.git.me@ttaylorr.com>\n\n\n* vd/fix-unaligned-read-index-v4 (2022-09-28) 1 commit\n  (merged to 'next' on 2022-09-28 at 5b3425fd58)\n + read-cache: avoid misaligned reads in index v4\n\n The codepath that reads from the index v4 had unaligned memory\n accesses, which has been corrected.\n source: <pull.1366.v2.git.1664385541084.gitgitgadget@gmail.com>\n\n--------------------------------------------------\n[New Topics]\n\n* ab/coding-guidelines-c99 (2022-10-10) 5 commits\n - CodingGuidelines: recommend against unportable C99 struct syntax\n - CodingGuidelines: mention C99 features we can't use\n - CodingGuidelines: allow declaring variables in for loops\n - CodingGuidelines: mention dynamic C99 initializer elements\n - CodingGuidelines: update for C99\n\n Update CodingGuidelines to clarify what features to use and avoid\n in C99.\n\n Will merge to 'next'?\n source: <20221010203800.2154698-1-gitster@pobox.com>\n\n\n* ds/bundle-uri-docfix (2022-10-07) 1 commit\n  (merged to 'next' on 2022-10-07 at 9ebc1e497a)\n + bundle-uri: fix technical doc issues\n\n Doc formatting fix.\n\n Will merge to 'master'.\n source: <pull.1377.git.1665157810025.gitgitgadget@gmail.com>\n\n\n* jc/symbolic-ref-no-recurse (2022-10-09) 1 commit\n - symbolic-ref: teach \"--[no-]recurse\" option\n\n After checking out a \"branch\" that is a symbolic-ref that points at\n another branch, \"git symbolic-ref HEAD\" reports the underlying\n branch, not the symbolic-ref the user gave checkout as argument.\n The command learned the \"--no-recurse\" option to stop after\n dereferencing a symbolic-ref only once.\n\n Will merge to 'next'?\n source: <xmqqleprcn08.fsf@gitster.g>\n\n\n* jc/use-of-uc-in-log-messages (2022-10-07) 1 commit\n - SubmittingPatches: use usual capitalization in the log message body\n\n Clarify that \"the sentence after <area>: prefix does not begin with\n a capital letter\" rule applies only to the commit title.\n\n Will merge to 'next'.\n source: <xmqqedvjfqx1.fsf@gitster.g>\n\n\n* ds/cmd-main-reorder (2022-10-08) 1 commit\n - git.c: improve code readability in cmd_main()\n\n Code clean-up.\n\n Will merge to 'next'?\n source: <pull.1355.v3.git.git.1665246097190.gitgitgadget@gmail.com>\n\n\n* ed/fsmonitor-inotify (2022-10-09) 6 commits\n . fsmonitor: update doc for Linux\n . fsmonitor: test updates\n . fsmonitor: enable fsmonitor for Linux\n . fsmonitor: implement filesystem change listener for Linux\n . fsmonitor: determine if filesystem is local or remote\n . fsmonitor: prepare to share code between Mac OS and Linux\n (this branch uses ed/fsmonitor-on-networked-macos.)\n\n Bundled fsmonitor for Linux using inotify API.\n\n Needs review.\n source: <pull.1326.v15.git.1664904751.gitgitgadget@gmail.com>\n source: <pull.1352.git.git.1665326258.gitgitgadget@gmail.com>\n\n\n* en/sparse-checkout-design (2022-10-08) 1 commit\n - sparse-checkout.txt: new document with sparse-checkout directions\n\n source: <pull.1367.v3.git.1665269538608.gitgitgadget@gmail.com>\n\n\n* jc/more-sanitizer-at-ci (2022-10-09) 1 commit\n - ci: add address and undefined sanitizer tasks\n\n\n* rs/use-fspathncmp (2022-10-08) 1 commit\n - dir: use fspathncmp() in pl_hashmap_cmp()\n\n Code clean-up.\n\n Will merge to 'next'.\n source: <cb6ffcdb-d719-7928-96b8-e46482dd141f@web.de>\n\n\n* jh/struct-zero-init-with-older-clang (2022-10-10) 1 commit\n - config.mak.dev: disable suggest braces error on old clang versions\n\n source: <pull.1375.v2.git.1665416340806.gitgitgadget@gmail.com>\n\n\n* od/ci-use-checkout-v3-when-applicable (2022-10-10) 2 commits\n - ci(main): linux32 uses actions/checkout@v2\n - ci(main): upgrade actions/checkout to v3\n\n source: <pull.1354.git.git.1665388136.gitgitgadget@gmail.com>\n\n\n* pw/remove-rebase-p-test (2022-10-10) 1 commit\n - t3435: remove redundant test case\n\n source: <pull.1379.git.1665395106351.gitgitgadget@gmail.com>\n\n--------------------------------------------------\n[Stalled]\n\n* ag/merge-strategies-in-c (2022-08-10) 14 commits\n - sequencer: use the \"octopus\" strategy without forking\n - sequencer: use the \"resolve\" strategy without forking\n - merge: use the \"octopus\" strategy without forking\n - merge: use the \"resolve\" strategy without forking\n - merge-octopus: rewrite in C\n - merge-recursive: move better_branch_name() to merge.c\n - merge-resolve: rewrite in C\n - merge-one-file: rewrite in C\n - update-index: move add_cacheinfo() to read-cache.c\n - merge-index: add a new way to invoke `git-merge-one-file'\n - merge-index: drop the index\n - merge-index: libify merge_one_path() and merge_all()\n - t6060: add tests for removed files\n - t6060: modify multiple files to expose a possible issue with merge-index\n\n An attempt to rewrite remaining merge strategies from shell to C.\n\n Needs more work.\n At the minimum, we should lose 11/14 and possibly 08/14.\n cf. <xmqq7d36vfur.fsf@gitster.g>\n source: <20220809185429.20098-1-alban.gruin@gmail.com>\n\n\n* po/glossary-around-traversal (2022-07-09) 3 commits\n - glossary: add reachability bitmap description\n - glossary: add commit graph description\n - glossary: add Object DataBase (ODB) abbreviation\n\n The glossary entries for \"commit-graph file\" and \"reachability\n bitmap\" have been added.\n\n Expecting a reroll.\n cf. <dfe0c1ab-33f8-f13e-71ce-1829bb0d2d7f@iee.email>\n source: <pull.1282.git.1657385781.gitgitgadget@gmail.com>\n\n\n* pw/rebase-keep-base-fixes (2022-09-07) 7 commits\n - rebase --keep-base: imply --no-fork-point\n - rebase --keep-base: imply --reapply-cherry-picks\n - rebase: factor out branch_base calculation\n - rebase: rename merge_base to branch_base\n - rebase: store orig_head as a commit\n - t3416: set $EDITOR in subshell\n - t3416: tighten two tests\n\n \"git rebase --keep-base\" used to discard the commits that are\n already cherry-picked to the upstream, even when \"keep-base\" meant\n that the base, on top of which the history is being rebuilt, does\n not yet include these cherry-picked commits.  The --keep-base\n option now implies --reapply-cherry-picks and --no-fork-point\n options.\n\n Expecting a reroll.\n cf. <e25127f3-6135-b716-a12f-5dbe4f40dc42@gmail.com>\n source: <pull.1323.v2.git.1662561470.gitgitgadget@gmail.com>\n\n\n* js/cmake-updates (2022-08-24) 5 commits\n - cmake: increase time-out for a long-running test\n - cmake: avoid editing t/test-lib.sh\n - add -p: avoid ambiguous signed/unsigned comparison\n - cmake: copy the merge tools for testing\n - cmake: make it easier to diagnose regressions in CTest runs\n\n Update to build procedure with VS using CMake/CTest.\n\n Expecting a reroll.\n cf. <3df77ffd-85a2-3a54-9005-34a24ec6e82d@github.com>\n cf. <531620e1-de4c-74aa-c840-c12ce81f8740@github.com> and others\n source: <pull.1320.v2.git.1661243463.gitgitgadget@gmail.com>\n\n\n* gc/submodule-clone-update-with-branches (2022-08-29) 6 commits\n - clone, submodule update: check out branches\n - submodule--helper: refactor up-to-date criterion\n - submodule: return target of submodule symref\n - t5617: drop references to remote-tracking branches\n - repo-settings: add submodule_propagate_branches\n - clone: teach --detach option\n\n \"git clone --recurse-submodules\" and \"git submodule update\" learns\n to honor the \"propagete branches\" option.\n\n Expecting a reroll.\n cf. <20220901200047.515294-1-jonathantanmy@google.com> and others\n source: <pull.1321.git.git.1661806456.gitgitgadget@gmail.com>\n\n\n* tb/diffstat-with-utf8-strwidth (2022-09-14) 1 commit\n - diff.c: use utf8_strwidth() to count display width\n\n \"git diff --stat\" etc. were invented back when everything was ASCII\n and strlen() was a way to measure the display width of a string;\n adjust them to compute the display width assuming UTF-8 pathnames.\n\n Expecting a reroll.\n source: <20220914151333.3309-1-tboegi@web.de>\n\n\n* mj/credential-helper-auth-headers (2022-09-13) 8 commits\n - http: set specific auth scheme depending on credential\n - http: move proactive auth to first slot creation\n - http: store all request headers on active_request_slot\n - credential: add WWW-Authenticate header to cred requests\n - http: read HTTP WWW-Authenticate response headers\n - osxkeychain: clarify that we ignore unknown lines\n - netrc: ignore unknown lines (do not die)\n - wincred: ignore unknown lines (do not die)\n\n Extending credential helper protocol.\n\n Expecting a reroll.\n A separate non-RFC submission of the first three is expected.\n cf. <AS8PR03MB86897FAC3E1E4F03D4420644C04F9@AS8PR03MB8689.eurprd03.prod.outlook.com>\n source: <pull.1352.git.1663097156.gitgitgadget@gmail.com>\n\n\n* cw/submodule-status-in-parallel (2022-09-23) 4 commits\n . diff-lib: parallelize run_diff_files for submodules\n . diff-lib: refactor functions\n . submodule: move status parsing into function\n . run-command: add pipe_output to run_processes_parallel\n\n Allow the internal \"diff-files\" engine to run \"how has this\n submodule changed?\" in parallel to speed up \"git status\".\n\n Breaks its self check.\n cf. https://github.com/git/git/actions/runs/3115673002/jobs/5052804463\n source: <20220922232947.631309-1-calvinwan@google.com>\n\n\n* es/mark-gc-cruft-as-experimental (2022-08-03) 2 commits\n - config: let feature.experimental imply gc.cruftPacks=true\n - gc: add tests for --cruft and friends\n\n Enable gc.cruftpacks by default for those who opt into\n feature.experimental setting.\n\n Expecting a reroll.\n cf. <220804.86a68ke9d5.gmgdl@evledraar.gmail.com>\n cf. <6803b725-526e-a1c8-f15c-a9ed4a144d4c@github.com>\n source: <20220803205721.3686361-1-emilyshaffer@google.com>\n\n\n* es/doc-creation-factor-fix (2022-07-28) 2 commits\n - range-diff: clarify --creation-factor=<factor>\n - format-patch: clarify --creation-factor=<factor>\n\n Expecting a reroll by somebody more familiar with the logic\n cf. <xmqqo7wfix7p.fsf@gitster.g>\n source: <7229p500-p2r4-on87-6802-8o90s36rr3s4@tzk.qr>\n\n\n* cw/remote-object-info (2022-08-13) 7 commits\n . SQUASH???\n . cat-file: add remote-object-info to batch-command\n . transport: add client support for object-info\n . serve: advertise object-info feature\n . protocol-caps: initialization bug fix\n . fetch-pack: move fetch initialization\n . fetch-pack: refactor packet writing\n\n A client component to talk with the object-info endpoint.\n\n Expecting a reroll.\n Under SANITIZE=address, t1006-cat-file.sh finds a breakage.\n cf. <20220728230210.2952731-1-calvinwan@google.com>\n cf. <CAFySSZDvgwbbHCHfyuaqX3tKsr-GjJ9iihygg6rNNe46Ys7_EA@mail.gmail.com>\n source: <20220728230210.2952731-1-calvinwan@google.com>\n\n--------------------------------------------------\n[Cooking]\n\n* jk/sequencer-missing-author-name-check (2022-10-03) 1 commit\n  (merged to 'next' on 2022-10-07 at 6a9f7e8b80)\n + sequencer: detect author name errors in read_author_script()\n\n Typofix in code.\n\n Will merge to 'master'.\n source: <YzsdRuD2CdJFdNVG@coredump.intra.peff.net>\n\n\n* pw/mailinfo-b-fix (2022-10-03) 1 commit\n  (merged to 'next' on 2022-10-07 at 5c5d79daef)\n + mailinfo -b: fix an out of bounds access\n\n Fix a logic in \"mailinfo -b\" that miscomputed the length of a\n substring, which lead to an out-of-bounds access.\n\n Will merge to 'master'.\n source: <pull.1372.git.1664789011089.gitgitgadget@gmail.com>\n\n\n* pw/ssh-sign-report-errors (2022-10-05) 1 commit\n  (merged to 'next' on 2022-10-07 at 4df1d2379a)\n + ssh signing: return an error when signature cannot be read\n\n The codepath to sign learned to report errors when it fails to read\n from \"ssh-keygen\".\n\n Will merge to 'master'.\n source: <pull.1371.v2.git.1664877694430.gitgitgadget@gmail.com>\n\n\n* ab/run-hook-api-cleanup (2022-10-05) 15 commits\n - run-command.c: don't copy \"ungroup\" to \"struct parallel_processes\"\n - run-command.c: don't copy *_fn to \"struct parallel_processes\"\n - run-command API: move *_tr2() users to \"run_processes_parallel()\"\n - run-command API: have run_process_parallel() take an \"opts\" struct\n - run-command API: make run_process_parallel{,_tr2}() thin wrappers\n - run-command API: add nascent \"struct run_process_parallel_opts\"\n - run-command.c: add an initializer for \"struct parallel_processes\"\n - run-command API: don't fall back on online_cpus()\n - run-command API: make \"jobs\" parameter an \"unsigned int\"\n - run-command API: have \"run_processes_parallel{,_tr2}()\" return void\n - run-command tests: use \"return\", not \"exit\"\n - run-command test helper: use \"else if\" pattern\n - run-command tests: test stdout of run_command_parallel()\n - submodule tests: reset \"trace.out\" between \"grep\" invocations\n - hook tests: fix redirection logic error in 96e7225b310\n\n Move a global variable added as a hack during regression fixes to\n its proper place in the API.\n\n Needs review.\n source: <cover-00.15-00000000000-20220930T111343Z-avarab@gmail.com>\n\n\n* nb/doc-mergetool-typofix (2022-10-05) 1 commit\n  (merged to 'next' on 2022-10-07 at d309a9a130)\n + mergetool.txt: typofix 'overwriten' -> 'overwritten'\n\n Typofix.\n\n Will merge to 'master'.\n source: <pull.1350.git.git.1664844924663.gitgitgadget@gmail.com>\n\n\n* rs/bisect-start-leakfix (2022-10-07) 1 commit\n - bisect--helper: plug strvec leak\n\n Code clean-up that results in plugging a leak.\n\n Will merge to 'next'.\n source: <1965b54b-122a-c965-f886-1a7dd6afbfb4@web.de>\n\n\n* rs/gc-pack-refs-simplify (2022-10-05) 1 commit\n  (merged to 'next' on 2022-10-07 at ef7d12408d)\n + gc: simplify maintenance_task_pack_refs()\n\n Code clean-up.\n\n Will merge to 'master'.\n source: <ab33f72e-d552-7bd7-bf04-3c476d32b5b6@web.de>\n\n\n* rs/test-httpd-in-C-locale (2022-10-06) 1 commit\n  (merged to 'next' on 2022-10-07 at 832c1e856a)\n + t/lib-httpd: pass LANG and LC_ALL to Apache\n\n Force C locale while running tests around httpd to make sure we can\n find expected error messages in the log.\n\n Will merge to 'master'.\n source: <a1699375-c660-13ab-42fb-26a8afe4c376@web.de>\n\n\n* ab/unused-annotation (2022-10-05) 1 commit\n - git-compat-util.h: GCC deprecated message arg only in GCC 4.5+\n\n Compilation fix for ancient compilers.\n\n Will merge to 'next'.\n source: <20221005221928.703750-1-asedeno@google.com>\n\n\n* dd/document-runtime-prefix-better (2022-10-05) 1 commit\n - Makefile: clarify runtime relative gitexecdir\n\n Doc updates.\n\n Will merge to 'next'.\n source: <20221006013205.15015-1-congdanhqx@gmail.com>\n\n\n* jk/cleanup-callback-parameters (2022-10-06) 4 commits\n - attr: drop DEBUG_ATTR code\n - commit: avoid writing to global in option callback\n - multi-pack-index: avoid writing to global in option callback\n - test-submodule: inline resolve_relative_url() function\n\n Code clean-up.\n\n Will merge to 'next'.\n source: <Yz7Tjy7Rh8cXVxYQ@coredump.intra.peff.net>\n source: <Yz7UhYXvNl6+1GbZ@coredump.intra.peff.net>\n\n\n* pw/test-todo (2022-10-06) 3 commits\n - test_todo: allow [verbose] test as the command\n - test_todo: allow [!] grep as the command\n - tests: add test_todo() to mark known breakages\n\n RFC for test framework improvement.\n\n Needs review.\n source: <pull.1374.git.1665068476.gitgitgadget@gmail.com>\n\n\n* jc/tmp-objdir (2022-09-30) 1 commit\n - tmp-objdir: skip clean up when handling a signal\n\n The code to clean temporary object directories (used for\n quarantine) tried to remove them inside its signal handler, which\n was a no-no.\n\n Will merge to 'next'.\n source: <pull.1348.v4.git.git.1664570831583.gitgitgadget@gmail.com>\n\n\n* jc/branch-description-unset (2022-09-30) 1 commit\n - branch: do not fail a no-op --edit-desc\n\n \"GIT_EDITOR=: git branch --edit-description\" resulted in failure,\n which has been corrected.\n\n Will merge to 'next'.\n source: <xmqqmtagka8x.fsf@gitster.g>\n\n\n* rj/branch-edit-desc-unborn (2022-10-07) 1 commit\n - branch: description for non-existent branch errors\n\n \"git branch --edit-description\" on an unborh branch misleadingly\n said that no such branch exists, which has been corrected.\n\n Will merge to 'next'.\n source: <8d627a2c-923f-181f-a03b-15f370c4dd0f@gmail.com>\n\n\n* jt/promisor-remote-fetch-tweak (2022-10-05) 2 commits\n - promisor-remote: die upon failing fetch\n - promisor-remote: remove a return value\n\n Remove error detection from a function that fetches from promisor\n remotes, and make it die when such a fetch fails to bring all the\n requested objects, to give an early failure to various operations.\n\n Will merge to 'next'.\n source: <cover.1664917853.git.jonathantanmy@google.com>\n\n\n* ed/fsmonitor-on-networked-macos (2022-10-05) 6 commits\n  (merged to 'next' on 2022-10-07 at fe9f182bde)\n + fsmonitor: add documentation for allowRemote and socketDir options\n + fsmonitor: check for compatability before communicating with fsmonitor\n + fsmonitor: deal with synthetic firmlinks on macOS\n + fsmonitor: avoid socket location check if using hook\n + fsmonitor: relocate socket file if .git directory is remote\n + fsmonitor: refactor filesystem checks to common interface\n (this branch is used by ed/fsmonitor-inotify.)\n\n By default, use of fsmonitor on a repository on networked\n filesystem is disabled. Add knobs to make it workable on macOS.\n\n Will merge to 'master'.\n source: <pull.1326.v15.git.1664904751.gitgitgadget@gmail.com>\n\n\n* rj/branch-edit-description-with-nth-checkout (2022-10-09) 2 commits\n - SQUASH???\n - branch: support for shortcuts like @{-1}, completed\n\n \"git branch --edit-description @{-1}\" is now a way to edit branch\n description of the branch you were on before switching to the\n current branch.\n\n Expecting a reroll.\n source: <de200fa0-379d-c1ce-8446-9e4292d0b66a@gmail.com>\n\n\n* rs/diff-caret-bang-with-parents (2022-10-01) 3 commits\n - diff: support ^! for merges\n - revisions.txt: unspecify order of resolved parts of ^!\n - revision: use strtol_i() for exclude_parent\n\n \"git diff rev^!\" did not show combined diff to go to the rev from\n its parents.\n\n Needs review.\n source: <16c49d20-cafc-4b48-3c6b-e11c74c29abb@web.de>\n\n\n* ab/doc-synopsis-and-cmd-usage (2022-10-05) 34 commits\n - tests: assert consistent whitespace in -h output\n - tests: start asserting that *.txt SYNOPSIS matches -h output\n - doc txt & -h consistency: make \"worktree\" consistent\n - worktree: define subcommand -h in terms of command -h\n - reflog doc: list real subcommands up-front\n - doc txt & -h consistency: make \"commit\" consistent\n - doc txt & -h consistency: make \"diff-tree\" consistent\n - doc txt & -h consistency: use \"[<label>...]\" for \"zero or more\"\n - doc txt & -h consistency: make \"annotate\" consistent\n - doc txt & -h consistency: make \"stash\" consistent\n - doc txt & -h consistency: add missing options\n - doc txt & -h consistency: use \"git foo\" form, not \"git-foo\"\n - doc txt & -h consistency: make \"bundle\" consistent\n - doc txt & -h consistency: make \"read-tree\" consistent\n - doc txt & -h consistency: make \"rerere\" consistent\n - doc txt & -h consistency: add missing options and labels\n - doc txt & -h consistency: make output order consistent\n - doc txt & -h consistency: add or fix optional \"--\" syntax\n - doc txt & -h consistency: fix mismatching labels\n - doc SYNOPSIS & -h: use \"-\" to separate words in labels, not \"_\"\n - doc txt & -h consistency: use \"<options>\", not \"<options>...\"\n - stash doc SYNOPSIS & -h: correct padding around \"[]()\"\n - doc txt & -h consistency: correct padding around \"[]()\"\n - doc txt & -h consistency: balance unbalanced \"[\" and \"]\"\n - doc txt & -h consistency: add \"-z\" to cat-file \"-h\"\n - doc txt & -h consistency: fix incorrect alternates syntax\n - doc txt & -h consistency: word-wrap\n - built-ins: consistently add \"\\n\" between \"usage\" and options\n - doc SYNOPSIS: consistently use ' for commands\n - doc SYNOPSIS: don't use ' for subcommands\n - bundle: define subcommand -h in terms of command -h\n - builtin/bundle.c: indent with tabs\n - CodingGuidelines: update and clarify command-line conventions\n - tests: assert *.txt SYNOPSIS and -h output\n\n The short-help text shown by \"git cmd -h\" and the synopsis text\n shown at the beginning of \"git help cmd\" have been made more\n consistent.\n\n Needs review.\n source: <cover-v4-00.34-00000000000-20221004T132211Z-avarab@gmail.com>\n\n\n* ab/coccicheck-incremental (2022-08-31) 9 commits\n - spatchcache: add a ccache-alike for \"spatch\"\n - cocci: optimistically use COMPUTE_HEADER_DEPENDENCIES\n - cocci: make \"coccicheck\" rule incremental\n - cocci: split off \"--all-includes\" from SPATCH_FLAGS\n - cocci: split off include-less \"tests\" from SPATCH_FLAGS\n - Makefile: split off SPATCH_BATCH_SIZE comment from \"cocci\" heading\n - Makefile: have \"coccicheck\" re-run if flags change\n - Makefile: add ability to TAB-complete cocci *.patch rules\n - cocci rules: remove unused \"F\" metavariable from pending rule\n\n \"make coccicheck\" is time consuming. It has been made to run more\n incrementally.\n\n Needs review.\n source: <cover-v2-0.9-00000000000-20220831T205130Z-avarab@gmail.com>\n\n\n* ds/bundle-uri-3 (2022-10-10) 12 commits\n - bundle-uri: suppress stderr from remote-https\n - bundle-uri: quiet failed unbundlings\n - bundle-uri: fetch a list of bundles\n - bundle: add flags to verify_bundle(), skip walk\n - bundle-uri: limit recursion depth for bundle lists\n - bundle-uri: parse bundle list in config format\n - bundle-uri: unit test \"key=value\" parsing\n - bundle-uri: create \"key=value\" line parsing\n - bundle-uri: create base key-value pair parsing\n - bundle-uri: create bundle_list struct and helpers\n - bundle-uri: use plain string in find_temp_filename()\n - Merge branch 'ds/bundle-uri-clone' into ds/bundle-uri-3\n\n Define the logical elements of a \"bundle list\", data structure to\n store them in-core, format to transfer them, and code to parse\n them.\n\n Needs review.\n source: <pull.1333.v4.git.1665417859.gitgitgadget@gmail.com>\n\n\n* js/bisect-in-c (2022-08-30) 17 commits\n - bisect: no longer try to clean up left-over `.git/head-name` files\n - bisect: remove Cogito-related code\n - Turn `git bisect` into a full built-in\n - bisect: move even the command-line parsing to `bisect--helper`\n - bisect--helper: make `state` optional\n - bisect--helper: calling `bisect_state()` without an argument is a bug\n - bisect: avoid double-quoting when printing the failed command\n - bisect run: fix the error message\n - bisect: verify that a bogus option won't try to start a bisection\n - bisect--helper: migrate to OPT_SUBCOMMAND()\n - bisect--helper: make the order consistently `argc, argv`\n - bisect--helper: make `terms` an explicit singleton\n - bisect--helper: simplify exit code computation\n - bisect--helper: really retire `--bisect-autostart`\n - bisect--helper: really retire --bisect-next-check\n - bisect--helper: retire the --no-log option\n - Merge branch 'sg/parse-options-subcommand' into js/bisect-in-c\n\n Final bits of \"git bisect.sh\" have been rewritten in C.\n\n Needs review.\n cf. <xmqqv8pr8903.fsf@gitster.g>\n source: <pull.1132.v6.git.1661885419.gitgitgadget@gmail.com>\n"},{"id":"464567","messageId":"Y0S7/jA5tNeoQ2Hm@coredump.intra.peff.net","threadId":"58596","inReplyTo":"xmqqlepnz1vu.fsf@gitster.g","subject":"Re: What's cooking in git.git (Oct 2022, #03; Mon, 10)","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2022-10-11T00:42:38Z","receivedAt":"2022-10-11T00:42:43Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Mon, Oct 10, 2022 at 04:37:25PM -0700, Junio C Hamano wrote:\n\n> * ed/fsmonitor-on-networked-macos (2022-10-05) 6 commits\n>   (merged to 'next' on 2022-10-07 at fe9f182bde)\n>  + fsmonitor: add documentation for allowRemote and socketDir options\n>  + fsmonitor: check for compatability before communicating with fsmonitor\n>  + fsmonitor: deal with synthetic firmlinks on macOS\n>  + fsmonitor: avoid socket location check if using hook\n>  + fsmonitor: relocate socket file if .git directory is remote\n>  + fsmonitor: refactor filesystem checks to common interface\n>  (this branch is used by ed/fsmonitor-inotify.)\n> \n>  By default, use of fsmonitor on a repository on networked\n>  filesystem is disabled. Add knobs to make it workable on macOS.\n> \n>  Will merge to 'master'.\n>  source: <pull.1326.v15.git.1664904751.gitgitgadget@gmail.com>\n\nThere's a tiny leak in this one. Here's a fix that can go on top.\n\n-- >8 --\nSubject: [PATCH] fsmonitor: fix leak of warning message\n\nThe fsm_settings__get_incompatible_msg() function returns an allocated\nstring.  So we can't pass its result directly to warning(); we must hold\non to the pointer and free it to avoid a leak.\n\nThe leak here is small and fixed size, but Coverity complained, and\npresumably SANITIZE=leaks would eventually.\n\nSigned-off-by: Jeff King <peff@peff.net>\n---\n fsmonitor.c | 4 +++-\n 1 file changed, 3 insertions(+), 1 deletion(-)\n\ndiff --git a/fsmonitor.c b/fsmonitor.c\nindex 540736b39f..08af00c738 100644\n--- a/fsmonitor.c\n+++ b/fsmonitor.c\n@@ -309,8 +309,10 @@ void refresh_fsmonitor(struct index_state *istate)\n \tenum fsmonitor_reason reason = fsm_settings__get_reason(r);\n \n \tif (!warn_once && reason > FSMONITOR_REASON_OK) {\n+\t\tchar *msg = fsm_settings__get_incompatible_msg(r, reason);\n \t\twarn_once = 1;\n-\t\twarning(\"%s\", fsm_settings__get_incompatible_msg(r, reason));\n+\t\twarning(\"%s\", msg);\n+\t\tfree(msg);\n \t}\n \n \tif (fsm_mode <= FSMONITOR_MODE_DISABLED ||\n-- \n2.38.0.705.gfa933d7c31\n\n"},{"id":"464587","messageId":"xmqqczazx7dn.fsf@gitster.g","threadId":"58596","inReplyTo":"Y0S7/jA5tNeoQ2Hm@coredump.intra.peff.net","subject":"Re: What's cooking in git.git (Oct 2022, #03; Mon, 10)","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2022-10-11T05:21:40Z","receivedAt":"2022-10-11T05:21:49Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Jeff King <peff@peff.net> writes:\n\n> There's a tiny leak in this one. Here's a fix that can go on top.\n>\n> -- >8 --\n> Subject: [PATCH] fsmonitor: fix leak of warning message\n>\n> The fsm_settings__get_incompatible_msg() function returns an allocated\n> string.  So we can't pass its result directly to warning(); we must hold\n> on to the pointer and free it to avoid a leak.\n>\n> The leak here is small and fixed size, but Coverity complained, and\n> presumably SANITIZE=leaks would eventually.\n>\n> Signed-off-by: Jeff King <peff@peff.net>\n> ---\n>  fsmonitor.c | 4 +++-\n>  1 file changed, 3 insertions(+), 1 deletion(-)\n\nIs there anybody else who is reading Coverity reports, I wonder.\nThis one is a clear positive.\n\nThanks.\n\n> diff --git a/fsmonitor.c b/fsmonitor.c\n> index 540736b39f..08af00c738 100644\n> --- a/fsmonitor.c\n> +++ b/fsmonitor.c\n> @@ -309,8 +309,10 @@ void refresh_fsmonitor(struct index_state *istate)\n>  \tenum fsmonitor_reason reason = fsm_settings__get_reason(r);\n>  \n>  \tif (!warn_once && reason > FSMONITOR_REASON_OK) {\n> +\t\tchar *msg = fsm_settings__get_incompatible_msg(r, reason);\n>  \t\twarn_once = 1;\n> -\t\twarning(\"%s\", fsm_settings__get_incompatible_msg(r, reason));\n> +\t\twarning(\"%s\", msg);\n> +\t\tfree(msg);\n>  \t}\n>  \n>  \tif (fsm_mode <= FSMONITOR_MODE_DISABLED ||\n"},{"id":"464605","messageId":"Y0Vq3iGifYeBxPbn@coredump.intra.peff.net","threadId":"58596","inReplyTo":"xmqqczazx7dn.fsf@gitster.g","subject":"Re: What's cooking in git.git (Oct 2022, #03; Mon, 10)","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2022-10-11T13:08:46Z","receivedAt":"2022-10-11T13:08:53Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Mon, Oct 10, 2022 at 10:21:40PM -0700, Junio C Hamano wrote:\n\n> Jeff King <peff@peff.net> writes:\n> \n> > There's a tiny leak in this one. Here's a fix that can go on top.\n> >\n> > -- >8 --\n> > Subject: [PATCH] fsmonitor: fix leak of warning message\n> >\n> > The fsm_settings__get_incompatible_msg() function returns an allocated\n> > string.  So we can't pass its result directly to warning(); we must hold\n> > on to the pointer and free it to avoid a leak.\n> >\n> > The leak here is small and fixed size, but Coverity complained, and\n> > presumably SANITIZE=leaks would eventually.\n> >\n> > Signed-off-by: Jeff King <peff@peff.net>\n> > ---\n> >  fsmonitor.c | 4 +++-\n> >  1 file changed, 3 insertions(+), 1 deletion(-)\n> \n> Is there anybody else who is reading Coverity reports, I wonder.\n> This one is a clear positive.\n\nI doubt it. My personal fork still has the coverity github-action which\nI showed last year[1]. We could merge that, but giving access to the\nproject is a minor pain. And of course the full list is full of false\npositives. One nice thing about coverity is that it marks each defect by\ndate, and tells you how many new ones there are. So when I push up my\nnext+personal branches build, I usually just skim over any new ones it\nreports. I'd say about 10% of them are actionable.\n\n-Peff\n\n[1] https://lore.kernel.org/git/YV5dmkkuCqAY2qqG@coredump.intra.peff.net/\n"},{"id":"469405","messageId":"92cc457a-d267-d20f-b516-295646b989ca@gmx.de","threadId":"58596","inReplyTo":"Y0Vq3iGifYeBxPbn@coredump.intra.peff.net","subject":"Re: What's cooking in git.git (Oct 2022, #03; Mon, 10)","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2022-12-20T23:11:54Z","receivedAt":"2022-12-20T23:12:18Z","isPatch":false,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"Hi Peff,\n\nOn Tue, 11 Oct 2022, Jeff King wrote:\n\n> On Mon, Oct 10, 2022 at 10:21:40PM -0700, Junio C Hamano wrote:\n>\n> > Jeff King <peff@peff.net> writes:\n> >\n> > > There's a tiny leak in this one. Here's a fix that can go on top.\n> > >\n> > > -- >8 --\n> > > Subject: [PATCH] fsmonitor: fix leak of warning message\n> > >\n> > > The fsm_settings__get_incompatible_msg() function returns an allocated\n> > > string.  So we can't pass its result directly to warning(); we must hold\n> > > on to the pointer and free it to avoid a leak.\n> > >\n> > > The leak here is small and fixed size, but Coverity complained, and\n> > > presumably SANITIZE=leaks would eventually.\n> > >\n> > > Signed-off-by: Jeff King <peff@peff.net>\n> > > ---\n> > >  fsmonitor.c | 4 +++-\n> > >  1 file changed, 3 insertions(+), 1 deletion(-)\n> >\n> > Is there anybody else who is reading Coverity reports, I wonder.\n> > This one is a clear positive.\n>\n> I doubt it.\n\nAs I mentioned to you previously (e.g. in\nhttps://lore.kernel.org/git/3896n74p-0r16-866o-r668-70q6pos078n9@tzk.qr/),\nI do have a look at them, usually a closer look during the -rc phases.\n\n> My personal fork still has the coverity github-action which I showed\n> last year[1]. We could merge that, but giving access to the project is a\n> minor pain. And of course the full list is full of false positives. One\n> nice thing about coverity is that it marks each defect by date, and\n> tells you how many new ones there are. So when I push up my\n> next+personal branches build, I usually just skim over any new ones it\n> reports. I'd say about 10% of them are actionable.\n\nThat 10% number does not match up with my experience.\n\nIn the v2.39.0-rc period, I looked through over a hundred new issues.\nPretty much all of them were strvec/strbuf false positives, and even the\nremaining ones were not actionable. (I typically glance over leaks such as\nthe one you reported, in favor of focusing on bugs that may cause crashes\nor other serious problems.)\n\nI also recall that\nhttps://lore.kernel.org/git/pull.1264.git.1655336146.gitgitgadget@gmail.com/\nwas the result of more than 150 new alerts that I sifted through, with 11\nactionable ones, some of which were later decided to be false positives\nafter all.\n\nCiao,\nJohannes\n"},{"id":"469446","messageId":"Y6OTR2iwcORPsTxz@coredump.intra.peff.net","threadId":"58596","inReplyTo":"92cc457a-d267-d20f-b516-295646b989ca@gmx.de","subject":"Re: What's cooking in git.git (Oct 2022, #03; Mon, 10)","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2022-12-21T23:14:15Z","receivedAt":"2022-12-21T23:14:21Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Wed, Dec 21, 2022 at 12:11:54AM +0100, Johannes Schindelin wrote:\n\n> > > Is there anybody else who is reading Coverity reports, I wonder.\n> > > This one is a clear positive.\n> >\n> > I doubt it.\n> \n> As I mentioned to you previously (e.g. in\n> https://lore.kernel.org/git/3896n74p-0r16-866o-r668-70q6pos078n9@tzk.qr/),\n> I do have a look at them, usually a closer look during the -rc phases.\n\nThanks for the reminder. I had a vague recollection that you were pretty\nnegative on Coverity's quality, but you do say pretty clearly there that\nyou'll continue with builds.\n\nThat said, I stand by the sentiment that hardly anybody is looking at\nthem. It sounds like it's mostly just you and me.\n\n> > My personal fork still has the coverity github-action which I showed\n> > last year[1]. We could merge that, but giving access to the project is a\n> > minor pain. And of course the full list is full of false positives. One\n> > nice thing about coverity is that it marks each defect by date, and\n> > tells you how many new ones there are. So when I push up my\n> > next+personal branches build, I usually just skim over any new ones it\n> > reports. I'd say about 10% of them are actionable.\n> \n> That 10% number does not match up with my experience.\n> \n> In the v2.39.0-rc period, I looked through over a hundred new issues.\n> Pretty much all of them were strvec/strbuf false positives, and even the\n> remaining ones were not actionable. (I typically glance over leaks such as\n> the one you reported, in favor of focusing on bugs that may cause crashes\n> or other serious problems.)\n\nMy counting method may be a bit more generous to Coverity. I build\n'next' (plus my local topics) every day or three, and get an email from\nCoverity if there's anything new. If so, I look at it. So I'm counting\n\"times I got an email and looked\" as the denominator, and the numerator\nis \"there was at least one useful warning\". So that skips some useless\nones that appear along side useful ones.\n\nI'm not sure how you saw a hundred new issues, though. My dashboard has\n10 unresolved issues total since the beginning of September, which is\nbefore 2.38 was released, and I think I sent 2 fixes since then (which\nare not counted, since they're now resolved, so 2/12).\n\nI do think it would be less noisy if we could somehow convince Coverity\nthat yes, strbuf really does NUL-terminate the result. But I haven't\nwanted to sink time into figuring out how to annotate it.\n\n-Peff\n"},{"id":"469452","messageId":"221222.867cyjx0d3.gmgdl@evledraar.gmail.com","threadId":"58596","inReplyTo":"Y6OTR2iwcORPsTxz@coredump.intra.peff.net","subject":"Re: What's cooking in git.git (Oct 2022, #03; Mon, 10)","fromName":"Ævar Arnfjörð Bjarmason","fromEmail":"avarab@gmail.com","sentAt":"2022-12-22T08:58:01Z","receivedAt":"2022-12-22T09:18:41Z","isPatch":false,"sender":{"key":"avarab@gmail.com","avatar":"https://avatars.githubusercontent.com/u/45301?v=4"},"body":"\nOn Wed, Dec 21 2022, Jeff King wrote:\n\n> I'm not sure how you saw a hundred new issues, though. My dashboard has\n> 10 unresolved issues total since the beginning of September, which is\n> before 2.38 was released, and I think I sent 2 fixes since then (which\n> are not counted, since they're now resolved, so 2/12).\n>\n> I do think it would be less noisy if we could somehow convince Coverity\n> that yes, strbuf really does NUL-terminate the result. But I haven't\n> wanted to sink time into figuring out how to annotate it.\n\nI don't have Coverity set up, but perhaps it's satisfied by the same\nthing that placeted GCC's -fanalyzers in strbuf.c:\n\n\thttps://lore.kernel.org/git/RFC-patch-07.15-cf1a5f3ed0f-20220603T183608Z-avarab@gmail.com/\n\nI run my local build with a version of that branch, I'd still like to\nfollow-up on it (and as that RFC thread shows others had some alternate\nsuggestions, e.g. for this strbuf case).\n\nI don't think it's true that a strbuf \"really does NUL-terminate the\nresult\" the way an analyzer like -fanalyzer sees it. I.e. if you do:\n\n\tstruct strbuf sb = { .alloc = 123 };\n\tstrbuf_addstr(&sb, \"blah\");\n\nYou'll segfault because the sb->buf isn't the slopbuf, nor\n'\\0'-terminated, it's just NULL.\n\nNow, we know we always init it with STRBUF_INIT or equivalent, but I\nthink it's correct to flag that if you're analyzing strbuf.c in\nisolation, as -fanalyze (and presumably Coverity) is doing.\n\n\n"},{"id":"469473","messageId":"Y6SWfOQrvOkLM67P@coredump.intra.peff.net","threadId":"58596","inReplyTo":"221222.867cyjx0d3.gmgdl@evledraar.gmail.com","subject":"Re: What's cooking in git.git (Oct 2022, #03; Mon, 10)","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2022-12-22T17:40:12Z","receivedAt":"2022-12-22T17:40:20Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Thu, Dec 22, 2022 at 09:58:01AM +0100, Ævar Arnfjörð Bjarmason wrote:\n\n> > I do think it would be less noisy if we could somehow convince Coverity\n> > that yes, strbuf really does NUL-terminate the result. But I haven't\n> > wanted to sink time into figuring out how to annotate it.\n> \n> I don't have Coverity set up, but perhaps it's satisfied by the same\n> thing that placeted GCC's -fanalyzers in strbuf.c:\n> \n> \thttps://lore.kernel.org/git/RFC-patch-07.15-cf1a5f3ed0f-20220603T183608Z-avarab@gmail.com/\n> \n> I run my local build with a version of that branch, I'd still like to\n> follow-up on it (and as that RFC thread shows others had some alternate\n> suggestions, e.g. for this strbuf case).\n\nI don't think that will help. The most common strbuf problem in Coverity\nis \"this string isn't NUL terminated\". And having walked through their\nstep-by-step analysis, I think what is going on is that it sees that:\n\n  strbuf_addstr(&sb, \"foo\");\n\nis doing:\n\n  memcpy(sb->buf, \"foo\", strlen(foo));\n\nunder the hood, and it says \"aha, this is an anti-pattern where you\nforgot to copy the NUL byte!\" and creates a warning. And it ignores\ncompletely the fact that the next line is calling strbuf_setlen() and\nadding the NUL byte.\n\nNow there may be other false positives around strbufs (like not\nrealizing the buffer grows), but this is the one I feel like I've seen\nthe most.\n\n> I don't think it's true that a strbuf \"really does NUL-terminate the\n> result\" the way an analyzer like -fanalyzer sees it. I.e. if you do:\n> \n> \tstruct strbuf sb = { .alloc = 123 };\n> \tstrbuf_addstr(&sb, \"blah\");\n> \n> You'll segfault because the sb->buf isn't the slopbuf, nor\n> '\\0'-terminated, it's just NULL.\n\nYeah, I didn't mean to say that there can't be real problems with\nstrbufs. I just meant that there are many false positives where the code\nis correct, but the tool doesn't realize it.\n\n-Peff\n"}]}