Description of problem: poptReadDefaultConfig reads /etc/popt twice Version-Release number of component (if applicable): popt-1.12-3.fc8 How reproducible: Deterministic Compile this program and debug/strace it: include <popt.h> int main(int argc, char *argv[] ) { poptContext ctx; ctx = poptGetContext( argv[0], argc, argv, NULL, 0); poptReadDefaultConfig( ctx, 1 ); } Steps to Reproduce: 1. compile this program: cat foo.c include <popt.h> int main(int argc, char *argv[] ) { poptContext ctx; ctx = poptGetContext( argv[0], argc, argv, NULL, 0); poptReadDefaultConfig( ctx, 1 ); } 2. debug or strace it. Actual results: # strace -o bla ./foo # grep /etc/popt bla open("/etc/popt", O_RDONLY|O_LARGEFILE) = 3 open("/etc/popt", O_RDONLY|O_LARGEFILE) = 3 Expected results: /etc/popt being opened only once. Additional info: The cause is this: From poptconfig.c ... rc = poptReadConfigFile(con, POPT_SYSCONFDIR "/popt"); if (rc) return rc; rc = poptReadConfigFile(con, "/etc/popt"); if (rc) return rc; ... If popt is being configured with --sysconfdir=/etc this causes the code fragment above to read /etc/popt twice.
Thanks for the report, Ralf. The problem was resolved in upstream CVS, further information here: http://www.rpm5.org/cvs/chngview?cn=8385 - IMHO this is only nasty and not critical nor should it cause any issue. I would wait for the next popt release instead of backporting it from CVS.
(In reply to comment #1) > IMHO this is only > nasty and not critical nor should it cause any issue. I would wait for the next > popt release instead of backporting it from CVS. Does popt allow recursive aliases/defines or similar? Then, this issue could cause pretty ugly effects, because each time /etc/popt is being read, a macro/alias/define would change itself, i.e. this issue would cause malfunctions.
There are no recursive things, the last definition always wins. Otherwise I would have pushed an update already.
Package: popt-1.13-1.fc8 Tag: dist-f8-updates-candidate Status: complete Package: popt-1.13-1.fc9 Tag: dist-f9 Status: complete An update for Fedora 8 is around the corner and already requested for testing repository. Please test it carefully and reopen the bug report, if it doesn't solve the problem for you. Please also add a comment at bodhi: https://admin.fedoraproject.org/updates/F8/pending/popt-1.13-1.fc8
popt-1.13-1.fc8 has been pushed to the Fedora 8 testing repository. If problems still persist, please make note of it in this bug report. If you want to test the update, you can install it with su -c 'yum --enablerepo=updates-testing update popt'
popt-1.13-1.fc8 has been pushed to the Fedora 8 stable repository. If problems still persist, please make note of it in this bug report.