Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(358)

Issue 1408393007: Possible fix for a null-pointer problem (Closed)

Created:
5 years, 2 months ago by Brian Wilkerson
Modified:
5 years, 2 months ago
Reviewers:
Leaf, Paul Berry
CC:
reviews_dartlang.org
Base URL:
https://github.com/dart-lang/sdk.git@master
Target Ref:
refs/heads/master
Visibility:
Public.

Description

Patch Set 1 #

Total comments: 3
Unified diffs Side-by-side diffs Delta from patch set Stats (+3 lines, -1 line) Patch
M pkg/analyzer/lib/src/context/context.dart View 1 chunk +3 lines, -1 line 3 comments Download

Messages

Total messages: 6 (1 generated)
Brian Wilkerson
I don't have a reproduction case, hence the lack of a test method. I can't ...
5 years, 2 months ago (2015-10-21 17:53:05 UTC) #2
Paul Berry
lgtm assuming the fix below is applied. https://codereview.chromium.org/1408393007/diff/1/pkg/analyzer/lib/src/context/context.dart File pkg/analyzer/lib/src/context/context.dart (right): https://codereview.chromium.org/1408393007/diff/1/pkg/analyzer/lib/src/context/context.dart#newcode1521 pkg/analyzer/lib/src/context/context.dart:1521: pendingFutures[i].forciblyComplete(); After ...
5 years, 2 months ago (2015-10-21 17:57:34 UTC) #3
Brian Wilkerson
https://codereview.chromium.org/1408393007/diff/1/pkg/analyzer/lib/src/context/context.dart File pkg/analyzer/lib/src/context/context.dart (right): https://codereview.chromium.org/1408393007/diff/1/pkg/analyzer/lib/src/context/context.dart#newcode1521 pkg/analyzer/lib/src/context/context.dart:1521: pendingFutures[i].forciblyComplete(); Good catch! Done.
5 years, 2 months ago (2015-10-21 18:05:02 UTC) #4
Brian Wilkerson
Committed patchset #1 (id:1) manually as 63865b5d1bda3861f4fd65edec38d99e44dd6ce4 (presubmit successful).
5 years, 2 months ago (2015-10-21 18:10:21 UTC) #5
Leaf
5 years, 2 months ago (2015-10-21 18:15:47 UTC) #6
Message was sent while issue was closed.
Thanks! I'll try it out.

https://codereview.chromium.org/1408393007/diff/1/pkg/analyzer/lib/src/contex...
File pkg/analyzer/lib/src/context/context.dart (right):

https://codereview.chromium.org/1408393007/diff/1/pkg/analyzer/lib/src/contex...
pkg/analyzer/lib/src/context/context.dart:1521:
pendingFutures[i].forciblyComplete();
On 2015/10/21 18:05:01, Brian Wilkerson wrote:
> Good catch! Done.

This is the same location that I was generally seeing the null cache entry
errors, so likely this will fix it.  I don't know if you want to pursue this
further, but I did observe that if you change the get method to throw an error
if it reaches the end of the method (which is not supposed to happen), then you
get a test failure:

python tools/test.py --host-checked -mrelease -cdart2analyzer -rnone -t240
language/internal_library_test/02

I didn't track it down any further at the time though.

Powered by Google App Engine
This is Rietveld 408576698