-
Bug
-
Resolution: Duplicate
-
Normal
-
None
-
rhel-8.10
-
None
-
None
-
Moderate
-
rhel-sst-cs-software-management
-
ssg_core_services
-
None
-
False
-
-
None
-
Red Hat Enterprise Linux
-
None
-
None
-
None
-
None
This is a continuation of SAT-26026 on the libdnf side of things.
What were you trying to do that didn't work?
A customer has a local repository with metadata in .zst format installed on a Sat 6.14 system (based on RHEL8.10). Because it's a Sat system, a specific libsolv-0.7.22-4.el8pc package is installed, which doesn't have zstd support inside, hence make solv_xfopen() function return 0.
This leads to having any dnf command crash in assertion:
# yum update [...] platform-python: /builddir/build/BUILD/libdnf-0.63.0/libdnf/dnf-sack.cpp:781: gboolean load_yum_repo(DnfSack*, HyRepo, GError**): Assertion `fp_primary' failed. Aborted (core dumped)
This assertion occurs because libdnf code assumes that solv_xfopen() never fails, which is just wrong (as seen above, see also analysis in SAT-26026):
722 static gboolean 723 load_yum_repo(DnfSack *sack, HyRepo hrepo, GError **error) 724 { : 780 fp_primary = solv_xfopen(primary.c_str(), "r"); 781 assert(fp_primary); :
Please harden this code to properly handle the possible error occurring on line 780.
Please provide the package NVR for which bug is seen:
libdnf-0.63.0-19.el8.x86_64
How reproducible:
Always
Steps to reproduce
- Setup a local repository with .zst metadata
- Install Sat 6.14 specific libsolv-0.7.22-4.el8pc
- Perform a yum update command
Expected results
Some self-explanatory error message (to be passed by libsolv itself to libdnf)
Actual results
Assertion
- duplicates
-
SAT-26026 dnf crashes in assertion because Sat's libsolv lacks ZST support
-
- New
-