Project

General

Profile

Bug #1646

~Cs assertion failure after setLimit()

Added by Anonymous over 5 years ago. Updated over 5 years ago.

Status:
Closed
Priority:
Normal
Category:
Tables
Target version:
Start date:
06/03/2014
Due date:
% Done:

100%

Estimated time:

Description

Cs' destructor triggers the following assertion if setLimit is used:

Assertion failed: (m_freeCsEntries.size() == m_nMaxPackets), function ~Cs, file ../daemon/table/cs.cpp, line 56.

It doesn't seem to matter if the limit is increased or decreased. Please see attached test cases.

Commit f4e89b40004daf757777d532e6f7dfee618cbaf6

cs-set-limit-assertion.cpp (1.89 KB) cs-set-limit-assertion.cpp Anonymous, 06/03/2014 12:22 PM

Related issues

Blocks NFD - Task #1623: Make ContentStore size configurableClosed

History

#1 Updated by Anonymous over 5 years ago

  • Blocks Task #1623: Make ContentStore size configurable added

#2 Updated by Alex Afanasyev over 5 years ago

  • Category set to Tables
  • Assignee set to Ilya Moiseenko
  • Target version set to v0.2

CS constructor pre-allocates the specified number of entries and setLimit doesn't do anything, except updating number of max packets and evicting items (and eventually causing segfault).

What we need here is to update setLimit to do this pre-allocation (re-allocation).

#3 Updated by Alex Afanasyev over 5 years ago

  • Status changed from New to In Progress
  • Assignee changed from Ilya Moiseenko to Alex Afanasyev

#4 Updated by Alex Afanasyev over 5 years ago

  • Status changed from In Progress to Code review
  • % Done changed from 0 to 100

#5 Updated by Alex Afanasyev over 5 years ago

  • Status changed from Code review to Closed

Applied in changeset commit:nfd|281b916a35ca1a0328eb84f76a90ca6cee50f00a.

Also available in: Atom PDF