FS#13437 - pacman segmentation fault when downloading from failing mirror

Attached to Project: Pacman
Opened by Michael Leuchtenburg (dyfrgi) - Monday, 23 February 2009, 22:57 GMT
Last edited by Dan McGee (toofishes) - Saturday, 28 February 2009, 19:12 GMT
Task Type Bug Report
Category Backend/Core
Status Closed
Assigned To No-one
Architecture All
Severity High
Priority Normal
Reported Version 3.2.2
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:
When running pacman -Sy, I experienced segmentation faults, every time it was run, and no successful update of package databases. Also, a junk file (size 20480) was left in /var/lib/pacman/core.db.tar.gz. This file contains mostly nulls, but does have a few strings in it (according to strings):
[2009-02-23 17:48] synchronizing package lists
core 10.0K 0.3K/s 00:01:06 [###########------------------------] 31%
linux-vdso.so.1
tls/x86_64/
/usr/lib/libalpm.so.3

Looks like random bits of memory, thus the segmentation fault.

I have verified that if I try to wget the core.db.tar.gz from the mirror directly, it simply stalls. It is able to get the size, but the data never shows up when requested from the FTP server. This is likely a server problem. The issue is that when this happens, pacman has a segmentation fault.

Additional info:
pacman v3.2.2
mirror ftp://mirror.cs.vt.edu/pub/ArchLinux/
x86_64 architecture

Steps to reproduce:
Configure the mirror.cs.vt.edu mirror as default
Run pacman -Sy
This task depends upon

Closed by  Dan McGee (toofishes)
Saturday, 28 February 2009, 19:12 GMT
Reason for closing:  Duplicate
Additional comments about closing:   FS#10773 
Comment by Allan McRae (Allan) - Monday, 23 February 2009, 23:51 GMT
It seems you are not the only one (http://bugs.archlinux.org/task/10773#comment40141). I wonder if this an  FS#10773  are really the same bug and this would give us a way to replicate it.
Comment by Dan McGee (toofishes) - Saturday, 28 February 2009, 19:11 GMT
I have seen one backtrace on this, and the fault is in libdownload with an invalid memcpy() if I remember right. This is indeed a dupe bug though, so let's consolidate comments there.

Loading...