Commit Graph

77384 Commits (maint)

Author SHA1 Message Date
Junio C Hamano f368df439b Merge branch 'maint-2.49' into maint-2.50
* maint-2.49:
  t: avoid git config syntax from newer releases
2025-07-08 15:42:33 -07:00
Junio C Hamano 47243eeed1 Merge branch 'maint-2.48' into maint-2.49
* maint-2.48:
  t: avoid git config syntax from newer releases
2025-07-08 15:42:14 -07:00
Junio C Hamano a1cf0cf13a Merge branch 'maint-2.47' into maint-2.48
* maint-2.47:
  t: avoid git config syntax from newer releases
2025-07-08 15:42:02 -07:00
Junio C Hamano 515a060550 Merge branch 'maint-2.46' into maint-2.47
* maint-2.46:
  t: avoid git config syntax from newer releases
2025-07-08 15:41:51 -07:00
Junio C Hamano 3d6d1296a4 Merge branch 'maint-2.45' into maint-2.46
This turns into a no-op merge, since more recent versions of Git
newer than 2.46 track do support the newer "git config" syntax.

* maint-2.45:
  t: avoid git config syntax from newer releases
2025-07-08 15:40:52 -07:00
Junio C Hamano a98e34b5a7 Merge branch 'maint-2.44' into maint-2.45
* maint-2.44:
  t: avoid git config syntax from newer releases
2025-07-08 15:35:35 -07:00
Junio C Hamano 09669c729a Merge branch 'maint-2.43' into maint-2.44
* maint-2.43:
  t: avoid git config syntax from newer releases
2025-07-08 15:33:02 -07:00
Junio C Hamano 18e6be837a Merge branch 'tz/avoid-newer-config-syntax-in-older-maint-tracks' into maint-2.43
* tz/avoid-newer-config-syntax-in-older-maint-tracks:
  t: avoid git config syntax from newer releases
2025-07-08 15:31:56 -07:00
Todd Zullinger 428c9241c6 t: avoid git config syntax from newer releases
In a recent security release, 05e9cd64ee (config: quote values
containing CR character, 2025-05-19) added calls to `git config get`,
`git config set`, and `git config unset` which are not present on the
maint-2.43 branch.

These subcommands were added in the following commits, released in
git-2.46.0:

  4e51389000 (builtin/config: introduce "get" subcommand, 2024-05-06),
  00bbdde141 (builtin/config: introduce "set" subcommand, 2024-05-06),
  95ea69c67b (builtin/config: introduce "unset" subcommand, 2024-05-06)

Revert to the previous `git config` syntax for older maintenance
branches.

Signed-off-by: Todd Zullinger <tmz@pobox.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2025-07-08 15:06:35 -07:00
Junio C Hamano 463c211685 Merge branch 'maint-2.49' into maint-2.50
* maint-2.49:
  Documentation/RelNotes: use .adoc extension for new security releases
2025-07-08 13:04:39 -07:00
Taylor Blau 7f5dd143ac Documentation/RelNotes: use .adoc extension for new security releases
When preparing the latest round of security fixes, we wrote release
notes in v2.43.7, and then successively merged those up through to the
various 'maint' branches.

However, the 2.49 release series is the first to have commit 1f010d6bdf
(doc: use .adoc extension for AsciiDoc files, 2025-01-20). This means
that we should have renamed the new-but-historical release notes from
*.txt to *.adoc during the merge into the 'maint-2.49' branch, but
neglected to do so.

Rename them accordingly to match the convention introduced by
1f010d6bdf. Since the release materials in question here were prepared
before v2.50.0 was tagged, the 'maint' track for that release series is
OK as is.

Signed-off-by: Taylor Blau <me@ttaylorr.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2025-07-08 13:03:27 -07:00
Junio C Hamano d82adb61ba Git 2.50.1 2025-06-15 21:57:08 -07:00
Junio C Hamano e1775c0646 Sync with 2.49.1 2025-06-15 21:54:23 -07:00
Junio C Hamano 16bd9f20a4 Git 2.50
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2025-06-15 21:17:21 -07:00
Junio C Hamano f1ca98f609 Hopefully final bits before 2.50
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2025-06-13 13:29:15 -07:00
Junio C Hamano 7bd3e5397d Merge branch 'js/github-ci-win-coverity-fix'
Fixes for GitHub Actions Coverity job.

* js/github-ci-win-coverity-fix:
  ci(coverity): output the build log upon error
  ci(coverity): fix building on Windows
2025-06-13 13:29:15 -07:00
Junio C Hamano e1f335f3d4 Merge branch 'ss/revert-builtin-bswap-stuff'
Revert a botched bswap.h change that broke ntohll() functions on
big-endian systems with __builtin_bswap32/64().

* ss/revert-builtin-bswap-stuff:
  Revert "bswap.h: add support for built-in bswap functions"
2025-06-13 13:29:14 -07:00
Junio C Hamano f2a6a1e596 Merge branch 'jc/sed-build-fixes'
Build fix.

* jc/sed-build-fixes:
  build: sed portability fixes
2025-06-13 13:29:14 -07:00
Junio C Hamano aadf8ae518 Git 2.49.1
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2025-06-13 07:51:58 -07:00
Junio C Hamano b2bfd317a3 l10n-2.50.0-v2
-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEE37vMEzKDqYvVxs51k24VDd1FMtUFAmhLZYwACgkQk24VDd1F
 MtUa3xAAuet6WgbUVN16q49Bd+WcK6uWooHlcpUMXANkJGqrjMquGfOCTc6bYXYi
 9JE87YUKxz5gIVP3YgEkJyLRiXuV0uUEfoGuXharQNDzMRfTNuhDmzV5drg7wWSJ
 CM0ErbD1jyHoPcuiusdhBCGAivV1k4WqofZ4OfhCUdapfpD1BnVXzNb6G6g6TemN
 WR5fiiQ2Ks0b8ZdfuXyBddqC44FOHwp4G1qgXBLoOq15matrNntb8y1ihualzTvp
 3M1LHNvh6HHwiD8lGcQiv/9Fjqbx6ypkUuxERiG90a53InKb5iYXA84MeYNbWm92
 rSpEpQOn3pq5ooweBLQWQUFOf/QFzFck6BtwHBdpH74FAkjXvjYs9aBPpH3PNUGW
 aXCTWZsvt2hEaYLMu3w54nrapnKUJMJrDRZn51+s88bk7s2fqY8yhfPduHh+fwu/
 4eVPQ9QgXiMS3sOTkU0tbV5qjw6LZFj9eb3Hg4MPQkwTQfe9x5mOOJC8IUOhwkuI
 bpb/V+PVYOcE4yv67qI51LeFkHt1ozWtxvXNJk3vEjcLSLDm3eBQTHo5t9wlpzsX
 pI3A985Fvzm7CQSr/0XPPGBLR1qnGjWXmOGe4v+N4VETnlPgqlv4nGEiLCFf+c8h
 4zwb/QaoTf7FLVKycEkBuiDohzGkuMUU1CICTTcPOJ7blwbGHjM=
 =2qMi
 -----END PGP SIGNATURE-----

Merge tag 'l10n-2.50.0-v2' of https://github.com/git-l10n/git-po

l10n-2.50.0-v2

* tag 'l10n-2.50.0-v2' of https://github.com/git-l10n/git-po:
  l10n: zh_TW: update translation for Git 2.50
2025-06-12 17:31:42 -07:00
Junio C Hamano a97f313784 Sync with 2.48.2
* maint-2.48:
  Git 2.48.2
  Git 2.47.3
  Git 2.46.4
  Git 2.45.4
  Git 2.44.4
  Git 2.43.7
  wincred: avoid buffer overflow in wcsncat()
  bundle-uri: fix arbitrary file writes via parameter injection
  config: quote values containing CR character
  git-gui: sanitize 'exec' arguments: convert new 'cygpath' calls
  git-gui: do not mistake command arguments as redirection operators
  git-gui: introduce function git_redir for git calls with redirections
  git-gui: pass redirections as separate argument to git_read
  git-gui: pass redirections as separate argument to _open_stdout_stderr
  git-gui: convert git_read*, git_write to be non-variadic
  git-gui: override exec and open only on Windows
  gitk: sanitize 'open' arguments: revisit recently updated 'open' calls
  git-gui: use git_read in githook_read
  git-gui: sanitize $PATH on all platforms
  git-gui: break out a separate function git_read_nice
  git-gui: assure PATH has only absolute elements.
  git-gui: remove option --stderr from git_read
  git-gui: cleanup git-bash menu item
  git-gui: sanitize 'exec' arguments: background
  git-gui: avoid auto_execok in do_windows_shortcut
  git-gui: sanitize 'exec' arguments: simple cases
  git-gui: avoid auto_execok for git-bash menu item
  git-gui: treat file names beginning with "|" as relative paths
  git-gui: remove unused proc is_shellscript
  git-gui: remove git config --list handling for git < 1.5.3
  git-gui: remove special treatment of Windows from open_cmd_pipe
  git-gui: remove HEAD detachment implementation for git < 1.5.3
  git-gui: use only the configured shell
  git-gui: remove Tcl 8.4 workaround on 2>@1 redirection
  git-gui: make _shellpath usable on startup
  git-gui: use [is_Windows], not bad _shellpath
  git-gui: _which, only add .exe suffix if not present
  gitk: encode arguments correctly with "open"
  gitk: sanitize 'open' arguments: command pipeline
  gitk: collect construction of blameargs into a single conditional
  gitk: sanitize 'open' arguments: simple commands, readable and writable
  gitk: sanitize 'open' arguments: simple commands with redirections
  gitk: sanitize 'open' arguments: simple commands
  gitk: sanitize 'exec' arguments: redirect to process
  gitk: sanitize 'exec' arguments: redirections and background
  gitk: sanitize 'exec' arguments: redirections
  gitk: sanitize 'exec' arguments: 'eval exec'
  gitk: sanitize 'exec' arguments: simple cases
  gitk: have callers of diffcmd supply pipe symbol when necessary
  gitk: treat file names beginning with "|" as relative paths

Signed-off-by: Taylor Blau <me@ttaylorr.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2025-06-12 17:13:35 -07:00
Junio C Hamano 9edff09aec Merge branch 'kh/maintenance-missing-tasks-docfix'
Doc mark-up fix for a topic that has graduated to 'master'.

* kh/maintenance-missing-tasks-docfix:
  doc: maintenance: fix linkgit syntax
2025-06-12 14:19:10 -07:00
Junio C Hamano 5acfacc2a1 build: sed portability fixes
Recently generating the version-def.h file and the config-list.h
file have been updated, which broke versions of "sed" that do not
want to be fed a file that ends with an incomplete line, and/or that
do not understand the more recent "-E" option to use extended
regular expression.

Fix them in response to a build-failure reported on Solaris boxes.

cf. https://lore.kernel.org/git/09f954b8-d9c3-418f-ad4b-9cb9b063f4ae@comstyle.com/

Reported-by: Brad Smith <brad@comstyle.com>
Reviewed-by: Collin Funk <collin.funk1@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2025-06-12 13:44:10 -07:00
Junio C Hamano 9b662a5d21 l10n-2.50.0-rnd1
-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEE37vMEzKDqYvVxs51k24VDd1FMtUFAmhK28EACgkQk24VDd1F
 MtU1GA/8CmvPedvJVqnaikUJTKRxrlyiqKkI8fAKqvqulubD36yI7QjDP4PhDKHA
 hK0uvJ16n4v4xp2aIATnD4E3AH3ocrjU5xzK1pqd26cYWdObKZeDpio/FQrEcJI2
 uPp+BHRnOVwg32gMHOEhry8rGtFlsZyCtoRSLPVPAN6Oy+NI4MfqJcN+FCtyWg5p
 oSTSwwbCXwUiuFXBjFgsCzq8Of/WRYr5cSfq/XCjz+0Gk57aLaVjnsVExxO6VwwB
 F5cdqbwuwbR7eGr3WJSGerNTfs4qKbVqbsxNDMLllI5OW/Kzm07nOdxNe4daoSbj
 9+DsNuOAe5mOdi09wx09B3QAMFiHOD8gJcTT4RbRXV+Fi3OZg782jIEzGKFmqccF
 7g7m74qsjk5GlswSXI8/l1l1mSPhBk4s6fcUkgF4aqO3F2QMIlCorEz5KE1J9H9R
 Xu+sMm46jLdCeVuz5obirE9XKOpdTlH1FQk02guskJgvCrXrmtzIBX6eYIUxewCO
 jyE4MYrVeY0PnIIMHMDJ1L+mg0hs6zyPjXiU7BQWHyYgLOQTp7q71slIYarpkj9o
 Md23cJwBhJV/lUqwuLCu6SwMBZlinYEN6QunRDbzl2oMBJjwz9VmrXbLzfqXujz4
 +ycA+efgGCN3JBU7qrvBME+jkT8dxn+4zoPFzwjfaXK2W9xXwbM=
 =O2DU
 -----END PGP SIGNATURE-----

Merge tag 'l10n-2.50.0-rnd1' of https://github.com/git-l10n/git-po

l10n-2.50.0-rnd1

* tag 'l10n-2.50.0-rnd1' of https://github.com/git-l10n/git-po:
  l10n: zh_CN: updated translation for 2.50
  l10n: Update German translation
  l10n: uk: add 2.50 translation
  l10n: po-id for 2.50
  l10n: bg.po: Updated Bulgarian translation (5819t)
  l10n: tr: Update Turkish translations for 2.50
  l10n: fr: v2.50 round 1
  l10n: Add full Irish translation (ga.po)
2025-06-12 13:35:08 -07:00
Sebastian Andrzej Siewior 1c62df0abe Revert "bswap.h: add support for built-in bswap functions"
Since 6547d1c9 (bswap.h: add support for built-in bswap
functions, 2025-04-23) tweaked the way the bswap32/64 macros are
defined, on platforms with __builtin_bswap32/64 supported, the
bswap32/64 macros are defined even on big endian platforms.

However the rest of this file assumes that bswap32/64() are defined
ONLY on little endian machines and uses that assumption to redefine
ntohl/ntohll macros. The said commit broke t4014-format-patch.sh test,
among many others on s390x.

Revert the commit.

Signed-off-by: Sebastian Andrzej Siewior <sebastian@breakpoint.cc>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2025-06-12 13:23:39 -07:00
Yi-Jyun Pan cbf346a996
l10n: zh_TW: update translation for Git 2.50
Signed-off-by: Yi-Jyun Pan <pan93412@gmail.com>
2025-06-12 22:29:32 +08:00
Teng Long 925035958b l10n: zh_CN: updated translation for 2.50
Helped-by: 依云 <lilydjwg@gmail.com>
Helped-by: Jiang Xin <zhiyou.jx@alibaba-inc.com>
Signed-off-by: Teng Long <dyroneteng@gmail.com>
2025-06-12 21:47:46 +08:00
Jiang Xin 36cbedb7cf Merge branch '2.50-uk-update' of https://github.com/arkid15r/git-ukrainian-l10n
* '2.50-uk-update' of https://github.com/arkid15r/git-ukrainian-l10n:
  l10n: uk: add 2.50 translation
2025-06-12 09:53:04 +08:00
Jiang Xin ee33b2ef37 Merge branch 'l10n-de-2.50' of https://github.com/ralfth/git
* 'l10n-de-2.50' of https://github.com/ralfth/git:
  l10n: Update German translation
2025-06-12 09:49:37 +08:00
Kristoffer Haugsbakk 1e2677f66f RelNotes/2.50.0: fix typos & other improvements
• Replace with phrases that are more standard (“all-or-nothing”
  instead of “-none”)
• Add coordinating words that make it less likely for you to trip
  over the sentence (“*that* "gc" can do”)
• Use “SMTP” instead of both SMTP and smtp
• Don’t mention `git fsck --reference` since the previous release
  was not affected by this minor bug.  Also say “errored out” since
  the git-refs(1) bug was there in v2.48.0 as well
• Use the more widespread “linked” instead of “secondary worktree”

Signed-off-by: Kristoffer Haugsbakk <code@khaugsbakk.name>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2025-06-11 13:32:14 -07:00
Johannes Schindelin 3cc4fc1ebd ci(coverity): output the build log upon error
It is quite helpful to know what Coverity said, exactly, in case it
fails to analyze the code.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2025-06-11 10:01:14 -07:00
Johannes Schindelin 882efe0444 ci(coverity): fix building on Windows
When I added the Coverity workflow in a56b6230d0 (ci: add a GitHub
workflow to submit Coverity scans, 2023-09-25), I merely converted an
Azure Pipeline definition that had been running successfully for ages.

In the meantime, the current Coverity documentation describes a very
different way to install the analysis tool, recommending to add the
`bin/` directory to the _end_ of `PATH` (when originally, IIRC, it was
recommended to add it to the _beginning_ of the `PATH`).

This is crucial! The reason is that the current incarnation of the
Windows variant of Coverity's analysis tools come with a _lot_ of DLL
files in their `bin/` directory, some of them interferring rather badly
with the `gcc.exe` in Git for Windows' SDK that we use to run the
Coverity build. The symptom is a cryptic error message:

  make: *** [Makefile:2960: headless-git.o] Error 1
  make: *** Waiting for unfinished jobs....
  D:\git-sdk-64-minimal\mingw64\bin\windres.exe: preprocessing failed.
  make: *** [Makefile:2679: git.res] Error 1
  make: *** [Makefile:2893: git.o] Error 1
  make: *** [Makefile:2893: builtin/add.o] Error 1
  Attempting to detect unconfigured compilers in build
  |0----------25-----------50----------75---------100|
  ****************************************************
  Warning:  Build command make.exe exited with code 2. Please verify that the build completed successfully.
  Warning:  Emitted 0 C/C++ compilation units (0%) successfully

  0 C/C++ compilation units (0%) are ready for analysis
   For more details, please look at:
      D:/a/git/git/cov-int/build-log.txt

The log (which the workflow is currently not configured to reveal) then
points out that the `windows.h` header cannot be found, which is _still_
not very helpful. The underlying root cause is that the `gcc.exe` in Git
for Windows' SDK determines the location of the header files via the
location of certain DLL files, and finding the "wrong" ones first on the
`PATH` misleads that logic.

Let's fix this problem by following Coverity's current recommendation
and append the `bin/` directory in which `cov-int` can be found to the
_end_ of `PATH`.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2025-06-11 10:01:14 -07:00
Ralf Thielow b21f7dd9e3 l10n: Update German translation
Signed-off-by: Ralf Thielow <ralf.thielow@gmail.com>
2025-06-11 16:56:18 +02:00
Arkadii Yakovets aeac109283
l10n: uk: add 2.50 translation
Co-authored-by: Kate Golovanova <kate@kgthreads.com>
Co-authored-by: Tamara Lazerka <98753789+aramattamara@users.noreply.github.com>
Signed-off-by: Arkadii Yakovets <ark@cho.red>
Signed-off-by: Kate Golovanova <kate@kgthreads.com>
Signed-off-by: Tamara Lazerka <98753789+aramattamara@users.noreply.github.com>
2025-06-10 18:23:00 -07:00
Jiang Xin a956283999 Merge branch 'po-id' of github.com:bagasme/git-po
* 'po-id' of github.com:bagasme/git-po:
  l10n: po-id for 2.50
2025-06-10 07:43:17 +08:00
Jiang Xin f6709fbc4a Merge branch 'master' of github.com:alshopov/git-po
* 'master' of github.com:alshopov/git-po:
  l10n: bg.po: Updated Bulgarian translation (5819t)
2025-06-10 07:42:34 +08:00
Jiang Xin 104807f89e Merge branch 'l10n_fr_v2.50' of github.com:jnavila/git
* 'l10n_fr_v2.50' of github.com:jnavila/git:
  l10n: fr: v2.50 round 1
2025-06-10 07:41:22 +08:00
Jiang Xin b0f9a659b2 Merge branch 'tr-l10n' of github.com:bitigchi/git-po
* 'tr-l10n' of github.com:bitigchi/git-po:
  l10n: tr: Update Turkish translations for 2.50
2025-06-10 07:39:49 +08:00
Jiang Xin 1963f3203a Merge branch 'master' of github.com:aindriu80/git-po
* 'master' of github.com:aindriu80/git-po:
  l10n: Add full Irish translation (ga.po)
2025-06-10 07:37:22 +08:00
Kristoffer Haugsbakk 6cd0701e3c doc: maintenance: fix linkgit syntax
Signed-off-by: Kristoffer Haugsbakk <code@khaugsbakk.name>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2025-06-09 11:33:25 -07:00
Junio C Hamano 4c0e625c09 Git 2.50-rc2
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2025-06-09 07:18:49 -07:00
Junio C Hamano 427b538fc3 Merge branch 'mm/test-in-absolute-home'
Tests that compare $HOME and $(pwd), which should be the same
directory unless the tests chdir's around, would fail when the user
enters the test directory via symbolic links, which has been
corrected.

* mm/test-in-absolute-home:
  t: run tests from a normalized working directory
2025-06-09 07:15:51 -07:00
Junio C Hamano 8db3019401 A bit more before -rc2
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2025-06-07 10:46:51 -07:00
Junio C Hamano 8546b3566e Merge branch 'js/curl-easy-setopt-typefix'
Adjust to newer version of libcURL.

* js/curl-easy-setopt-typefix:
  curl: pass `long` values where expected
2025-06-07 10:46:50 -07:00
Junio C Hamano 7558d89423 Merge branch 'jk/curl-easy-setopt-typefix'
Adjust to newer version of libcURL.

* jk/curl-easy-setopt-typefix:
  curl: fix symbolic constant typechecks with curl_easy_setopt()
  curl: fix integer variable typechecks with curl_easy_setopt()
  curl: fix integer constant typechecks with curl_easy_setopt()
2025-06-07 10:46:50 -07:00
Junio C Hamano c20471e465 Merge branch 'bs/bsd-wo-specific-xopen-source'
Build fix for BSDs.

* bs/bsd-wo-specific-xopen-source:
  compat: fixes for header handling with OpenBSD / NetBSD
2025-06-07 10:46:50 -07:00
Junio C Hamano e2e22932cd Merge branch 'cf/var-completion-obsd-fixes'
Build fix for OpenBSD.

* cf/var-completion-obsd-fixes:
  completion: make sed command that generates config-list.h portable.
2025-06-07 10:46:49 -07:00
Bagas Sanjaya 642fd4ff36 l10n: po-id for 2.50
Update following components:

  * builtin/cat-file.c
  * builtin/fast-export.c
  * builtin/fsck.c
  * builtin/merge-tree.c
  * builtin/mv.c
  * builtin/reflog.c
  * builtin/repack.c
  * builtin/rev-list.c
  * builtin/update-ref.c
  * command-list.h
  * midx-write.c
  * object-file.c
  * parse-options.c
  * promisor-remote.c
  * refs/packed-backend.c
  * scalar.c
  * t/helper/test-pack-deltas.c
  * git-send-email.perl

Translate following new components:

  * builtin/diff-pairs.c

Signed-off-by: Bagas Sanjaya <bagasdotme@gmail.com>
2025-06-07 08:27:57 +07:00
Junio C Hamano 83cb7ae638 Merge branch 'master' of https://github.com/j6t/git-gui
* 'master' of https://github.com/j6t/git-gui:
  git-gui: don't delete source files when auto_mkindex fails
2025-06-06 09:41:59 -07:00
Johannes Schindelin 229d12665e curl: pass `long` values where expected
As of Homebrew's update to cURL v8.14.0, there are new compile errors to
be observed in the `osx-gcc` job of Git's CI builds:

  In file included from http.h:8,
                   from imap-send.c:36:
  In function 'setup_curl',
      inlined from 'curl_append_msgs_to_imap' at imap-send.c:1460:9,
      inlined from 'cmd_main' at imap-send.c:1581:9:
  /usr/local/Cellar/curl/8.14.0/include/curl/typecheck-gcc.h:50:15: error: call to '_curl_easy_setopt_err_long' declared with attribute warning: curl_easy_setopt expects a long argument [-Werror=attribute-warning]
     50 |               _curl_easy_setopt_err_long();                             \
        |               ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
  /usr/local/Cellar/curl/8.14.0/include/curl/curl.h:54:7: note: in definition of macro 'CURL_IGNORE_DEPRECATION'
     54 |       statements \
        |       ^~~~~~~~~~
  imap-send.c:1423:9: note: in expansion of macro 'curl_easy_setopt'
   1423 |         curl_easy_setopt(curl, CURLOPT_PORT, srvc->port);
        |         ^~~~~~~~~~~~~~~~
  [... many more instances of nearly identical warnings...]

See for example this CI workflow run:
https://github.com/git/git/actions/runs/15454602308/job/43504278284#step:4:307

The most likely explanation is the entry "typecheck-gcc.h: fix the
typechecks" in cURL's release notes (https://curl.se/ch/8.14.0.html).

Nearly identical compile errors afflicted recently-updated Debian
setups, which have been addressed by `jk/curl-easy-setopt-typefix`.

However, on macOS Git is built with different build options, which
uncovered more instances of `int` values that need to be cast to
constants, which were not covered by 6f11c42e8e (curl: fix integer
constant typechecks with curl_easy_setopt(), 2025-06-04). Let's
explicitly convert even those remaining `int` constants in
`curl_easy_setopt()` calls to `long` parameters.

In addition to looking at the compile errors of the `osx-gcc` job, I
verified that there are no other instances of the same issue that need
to be handled in this manner (and that might not be caught by our CI
builds because of yet other build options that might skip those code
parts), I ran the following command and inspected all 23 results
manually to ensure that the fix is now actually complete:

  git grep -n curl_easy_setopt |
  grep -ve ',.*, *[A-Za-z_"&]' \
    -e ',.*, *[-0-9]*L)' \
    -e ',.*,.* (long)'

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2025-06-06 08:12:24 -07:00