[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#759612: apt: apt-cache segfaults when given some options



David Kalnischkies <david@kalnischkies.de> writes:

> Hi,
>
> On Thu, Aug 28, 2014 at 05:27:28PM -0700, Dima Kogan wrote:
>>  dima@shorty:~$ apt-cache search ^xxx-
>>  zsh: segmentation fault (core dumped)  apt-cache search ^xxx-
>
> Could you run the command in gdb maybe?

Hi David. Thank you for looking at this. Looking a bit more deeply, it
looks like my shell was expanding ^xxx- to a list of all files in the
local directory, and the cause of the crash was simply too many
arguments. The following crashes consistently for me:

 apt-cache search xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx

There are 133 'xxx' here. This appears to be the threshold. >= 133
arguments causes a crash. < 133 arguments works ok. This is admittedly
more of a corner case, but it still shouldn't crash.

dima


Reply to: