https://redmine.named-data.net/https://redmine.named-data.net/favicon.ico?14759811232015-06-09T13:58:26ZNDN project issue tracking systemndn-cxx - Bug #2865: Possible false remove in Face::cancelPendingInterest (address used as handle)https://redmine.named-data.net/issues/2865?journal_id=103882015-06-09T13:58:26ZAlex Afanasyev
<ul></ul><p>I understand the issue, but don't really want to do anything about it. Chance that this would happen is small and chance that this would negatively affect application in a major way is even smaller.</p>
ndn-cxx - Bug #2865: Possible false remove in Face::cancelPendingInterest (address used as handle)https://redmine.named-data.net/issues/2865?journal_id=108702015-06-24T14:15:28ZAnonymous
<ul></ul><p>If nobody else has any discussion, we can abandon this.</p>
ndn-cxx - Bug #2865: Possible false remove in Face::cancelPendingInterest (address used as handle)https://redmine.named-data.net/issues/2865?journal_id=108712015-06-24T14:19:42ZJunxiao Shi
<ul><li><strong>Description</strong> updated (<a title="View differences" href="/journals/10871/diff?detail_id=9807">diff</a>)</li><li><strong>Category</strong> set to <i>Base</i></li><li><strong>Target version</strong> set to <i>Unsupported</i></li></ul><p>This is a valid Bug report and should not be abandoned. I have marked TargetVersion=Unsupported to indicate that there's no recent plan to fix this problem.</p>
ndn-cxx - Bug #2865: Possible false remove in Face::cancelPendingInterest (address used as handle)https://redmine.named-data.net/issues/2865?journal_id=246882019-02-06T21:59:41ZDavide Pesavento
<ul><li><strong>Subject</strong> changed from <i>Possible false remove in removePendingInterest (address used as ID)</i> to <i>Possible false remove in Face::cancelPendingInterest (address used as handle)</i></li><li><strong>Target version</strong> changed from <i>Unsupported</i> to <i>v0.7</i></li><li><strong>Start date</strong> deleted (<del><i>06/09/2015</i></del>)</li></ul><p>The described sequence of events has become a lot more likely with the introduction of <code>ScopedPendingInterestHandle</code> (<a class="issue tracker-2 status-5 priority-2 priority-default closed" title="Feature: Scoped expressed Interest (Closed)" href="https://redmine.named-data.net/issues/4316">#4316</a>).<br>
One of its most common usage patterns is assigning the result of <code>expressInterest</code> to a class member field of type <code>ScopedPendingInterestHandle</code> when re-expressing an Interest that has timed out or has been nacked. As Jeff said, <code>expressInterest</code> may allocate a copy of the new Interest at the same memory address[1] as the timed-out/nacked Interest. If that happens, when <code>expressInterest</code> returns and its result is assigned to the handle, the move assignment operator will try to cancel the old (timed-out) Interest but it will in fact end up canceling the <em>new</em> (just re-expressed) Interest.</p>
<p>[1] In some circumstances, if the pattern of memory (de)allocations repeats itself over and over, the memory addresses of newly allocated objects are <em>very</em> predictable (same address >90% of the time in my tests).</p>
ndn-cxx - Bug #2865: Possible false remove in Face::cancelPendingInterest (address used as handle)https://redmine.named-data.net/issues/2865?journal_id=246932019-02-08T05:16:36ZJunxiao Shi
<ul><li><strong>Status</strong> changed from <i>New</i> to <i>In Progress</i></li><li><strong>Assignee</strong> set to <i>Junxiao Shi</i></li><li><strong>Estimated time</strong> set to <i>3.00 h</i></li></ul> ndn-cxx - Bug #2865: Possible false remove in Face::cancelPendingInterest (address used as handle)https://redmine.named-data.net/issues/2865?journal_id=246942019-02-08T05:45:36ZJunxiao Shi
<ul><li><strong>Status</strong> changed from <i>In Progress</i> to <i>Code review</i></li><li><strong>% Done</strong> changed from <i>0</i> to <i>80</i></li></ul><p><a href="https://gerrit.named-data.net/5233">https://gerrit.named-data.net/5233</a> assigns <code>PendingInterestId</code> from an atomic counter to avoid duplicates.</p>
ndn-cxx - Bug #2865: Possible false remove in Face::cancelPendingInterest (address used as handle)https://redmine.named-data.net/issues/2865?journal_id=246972019-02-08T12:32:35ZJunxiao Shi
<ul></ul><p>The same bug also occurs on <code>InterestFilterId</code> and <code>RegisteredPrefixId</code>. Since they aren't causing test failures now, I'll fix them in <a class="issue tracker-2 status-5 priority-2 priority-default closed" title="Feature: Scoped prefix registration (Closed)" href="https://redmine.named-data.net/issues/3919">#3919</a>.</p>
<blockquote>
<p>we should eventually (after we've removed PendingInterestId from the public API) switch to <code>using PendingInterestId = std::uintptr_t;</code> and change all "const PendingInterestId*" to just "PendingInterestId"</p>
</blockquote>
<p>Yes, and probably more than that.</p>
ndn-cxx - Bug #2865: Possible false remove in Face::cancelPendingInterest (address used as handle)https://redmine.named-data.net/issues/2865?journal_id=250112019-03-15T12:31:35ZJunxiao Shi
<ul><li><strong>Status</strong> changed from <i>Code review</i> to <i>Closed</i></li><li><strong>% Done</strong> changed from <i>80</i> to <i>100</i></li></ul> ndn-cxx - Bug #2865: Possible false remove in Face::cancelPendingInterest (address used as handle)https://redmine.named-data.net/issues/2865?journal_id=250132019-03-15T13:08:00ZDavide Pesavento
<ul></ul><p>Junxiao Shi wrote:</p>
<blockquote>
<p>The same bug also occurs on <code>InterestFilterId</code> and <code>RegisteredPrefixId</code>. Since they aren't causing test failures now, I'll fix them in <a class="issue tracker-2 status-5 priority-2 priority-default closed" title="Feature: Scoped prefix registration (Closed)" href="https://redmine.named-data.net/issues/3919">#3919</a>.</p>
</blockquote>
<p>Has this been done? I don't see the commits in <a class="issue tracker-2 status-5 priority-2 priority-default closed" title="Feature: Scoped prefix registration (Closed)" href="https://redmine.named-data.net/issues/3919">#3919</a></p>