Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines
Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.
REPEAT: Do NOT report bugs for outdated packages!
https://wiki.archlinux.org/title/Bug_reporting_guidelines
Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.
REPEAT: Do NOT report bugs for outdated packages!
FS#754 - Pacman segfaults during dependency checks (pacman -T)
|
Details$ pacman -T xfree86
Segmentation fault. $ gdb pacman (gdb) run -T xfree86 Starting program: /usr/bin/pacman -T xfree86 Program received signal SIGSEGV, Segmentation fault. list_free (list=0x590) at src/list.c:47 47 if(list->data != NULL) { (gdb) bt #0 list_free (list=0x590) at src/list.c:47 #1 0x080546a6 in freepkg (pkg=0x81c02e8) at src/package.c:268 #2 0x0804897e in pacman_deptest (db=0x80e8408, targets=0x819f750) at src/pacman.c:265 #3 0x080485d5 in main (argc=135169032, argv=0xbffff754) at src/pacman.c:229 (gdb) List is non-null (so the entry check in list_free doesn't catch it), but it's obviously an uninitialized pointer. Further up the stack we get: (gdb) return Make list_free return now? (y or n) y #0 0x080546a6 in freepkg (pkg=0x81c02e8) at src/package.c:268 268 FREELIST(pkg->provides); (gdb) p pkg->provides $1 = (PMList *) 0x590 (gdb) pkg->provides is not being initialized. I'll see if I can figure out why, and send you a patch. Just thought you should know. |
This task depends upon
dummy is returned by newpkg(), which does this:
pkg->provides = NULL;
then deptest calls freepkg(), which does this:
FREELIST(pkg->files);
FREELIST(pkg->backup);
FREELIST(pkg->depends);
FREELIST(pkg->conflicts);
FREELIST(pkg->requiredby);
FREELIST(pkg->groups);
FREELIST(pkg->provides);
FREELIST(pkg->replaces);
FREE(pkg);
And somehow pkg->provides == non-null?
(gdb) p pkg->provides
$1 = (PMList *) 0x590
(gdb)
When you fix this (Xentac tells me you already have :D), mind telling me exactly where this damn bug was so I can stop scratching my head. I can't see it anywhere, hehe