Skip to content

Panic due to nil maps#3042

Merged
srfrog merged 2 commits intomasterfrom
srfrog/issue-3401_query_panic_assignment_nil_map
Feb 19, 2019
Merged

Panic due to nil maps#3042
srfrog merged 2 commits intomasterfrom
srfrog/issue-3401_query_panic_assignment_nil_map

Conversation

@srfrog
Copy link
Copy Markdown
Contributor

@srfrog srfrog commented Feb 19, 2019

A couple of missing map initializations in varValue were causing panic when those fields were being accessed from fillVars().

Closes #3041


This change is Reviewable

srfrog added 2 commits February 19, 2019 12:14
varValue assignments were missing map initialization for Vars
field causing panic when accessed later in fillVars().
@srfrog srfrog requested a review from a team February 19, 2019 19:19
Copy link
Copy Markdown
Contributor

@manishrjain manishrjain left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:lgtm: Once it passes all tests, let's get it merged. And then cherry-pick in release/v1.0 branch.

Reviewed 2 of 2 files at r1.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved

@srfrog srfrog merged commit bce2393 into master Feb 19, 2019
@srfrog srfrog deleted the srfrog/issue-3401_query_panic_assignment_nil_map branch February 19, 2019 20:16
dna2github pushed a commit to dna2fork/dgraph that referenced this pull request Jul 19, 2019
* query/query.go: var assignment was missing map init

varValue assignments were missing map initialization for Vars
field causing panic when accessed later in fillVars().

* query/query0_test.go: added tests that found the bug
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants