Bug 2368357 - Memory leak with libcurl-8.14.0~rc1-1.fc43.x86_64 in cargo
Summary: Memory leak with libcurl-8.14.0~rc1-1.fc43.x86_64 in cargo
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: curl
Version: rawhide
Hardware: All
OS: Linux
unspecified
urgent
Target Milestone: ---
Assignee: Jan Macku
QA Contact: Fedora Extras Quality Assurance
URL: https://discussion.fedoraproject.org/...
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2025-05-24 11:16 UTC by mado
Modified: 2025-05-31 11:37 UTC (History)
9 users (show)

Fixed In Version: curl-8.14.0-1.fc43
Clone Of:
Environment:
Last Closed: 2025-05-29 11:07:28 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description mado 2025-05-24 11:16:09 UTC
The update from libcurl-8.13.0-1.fc43.x86_64 to libcurl-8.14.0~rc1-1.fc43.x86_64 causes cargo to memleak when accessing the Internet.

For more information on how this conclusion is drawn: https://discussion.fedoraproject.org/t/rawhide-anyone-aware-of-why-cargo-has-been-memleaking/154420


Reproducible: Always

Steps to Reproduce:
dnf in -y cargo git wget
wget https://crates.io/api/v1/crates/mise/2025.5.11/download#/mise-2025.5.11.crate
tar xf download
cd mise*/
# this is the expansion of %cargo_license_summary_online in anda-srpm-macros
(
set -euo pipefail
/usr/bin/env CARGO_HOME=.cargo RUSTC_BOOTSTRAP=1 RUSTFLAGS='-Copt-level=3 -Cdebuginfo=2 -Ccodegen-units=1 -Cstrip=none -Cforce-frame-pointers=yes --cap-lints=warn' /usr/bin/cargo tree -Z avoid-dev-deps --workspace --edges no-build,no-dev,no-proc-macro --no-dedupe --target all --prefix none --format "# {l}" | sed -e "s: / :/:g" -e "s:/: OR :g" | sort -u
)
Actual Results:
ruffle-nightly spec: https://github.com/terrapkg/packages/blob/frawhide/anda/apps/ruffle/ruffle-nightly.spec
ruffle-nightly ci: https://github.com/terrapkg/packages/actions/runs/15222318615/job/42819783301
mise spec: https://github.com/terrapkg/packages/blob/frawhide/anda/tools/buildsys/mise/rust-mise.spec
mise ci: https://github.com/terrapkg/packages/actions/runs/15214974288/job/42798225381

Following is the logs for ruffle-nightly:

rpmbuild │ + /usr/bin/env CARGO_HOME=.cargo RUSTC_BOOTSTRAP=1 'RUSTFLAGS=-Copt-level=3 -Cdebuginfo=2 -Ccodegen-units=1 -Cstrip=none -Cforce-frame-pointers=yes -Clink-arg=-specs=/usr/lib/rpm/redhat/redhat-package-notes --cap-lints=warn -C link-arg=-fuse-ld=mold' /usr/bin/cargo build -j4 -Z avoid-dev-deps --profile rpm
rpmbuild │ warning: both `/github/home/rpmbuild/BUILD/ruffle-nightly-20250523-build/ruffle-nightly-2025-05-23/.cargo/config` and `/github/home/rpmbuild/BUILD/ruffle-nightly-20250523-build/ruffle-nightly-2025-05-23/.cargo/config.toml` exist. Using `/github/home/rpmbuild/BUILD/ruffle-nightly-20250523-build/ruffle-nightly-2025-05-23/.cargo/config`
rpmbuild │     Updating crates.io index
rpmbuild │     Updating git repository `https://github.com/ruffle-rs/rust-flash-lso`
rpmbuild │     Updating git repository `https://github.com/ruffle-rs/nellymoser`
rpmbuild │     Updating git repository `https://github.com/ruffle-rs/regras3`
rpmbuild │     Updating git repository `https://github.com/ruffle-rs/h263-rs`
rpmbuild │     Updating git repository `https://github.com/ruffle-rs/nihav-vp6`
rpmbuild │     Updating git repository `https://github.com/kyren/gc-arena.git`
rpmbuild │  Downloading crates ...
rpmbuild │ error: failed to download `unicode-segmentation v1.12.0`
rpmbuild │ 
rpmbuild │ Caused by:
rpmbuild │   Out of memory
rpmbuild │ error: Bad exit status from /var/tmp/rpm-tmp.SldqOd (%build)

Expected Results:
It should not memory leak.

Additional Information:
Only reproducible on Fedora Rawhide, not 42, 41, ...

Only reproducible when cargo has Internet access (which is why it works fine with Fedora builders, but not on Terra).

Also reproducible with `%cargo_build` or `%cargo_install` with Internet access.

Setting severity to urgent since a memory leak… crashes computers.

Comment 1 Jan Macku 2025-05-29 11:07:28 UTC
I have rebased to the latest version. Feel free to reopen this issue if your problem persists.


Note You need to log in before you can comment on or make changes to this bug.