Skip to content

Don't compare nullptr string - Fixes #120 #121

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 2, 2020
Merged

Conversation

phord
Copy link
Contributor

@phord phord commented May 30, 2020

In AdafruitIO_Group::call there is a comparison with the feedname
of the update. If the onMessage() call didn't provide a feed name,
the feed pointer is null. The code also checks for this, but
it does it after comparing with a string. Reverse the check
so a short-circuiting or can do the right thing.

In AdafruitIO_Group::call there is a comparison with the feedname
of the update. If the onMessage() call didn't provide a feed name,
the feed pointer is null.  The code also checks for this, but
it does it after comparing with a string.  Reverse the check
so a short-circuiting or can do the right thing.
@brentru brentru self-requested a review June 1, 2020 15:00
Copy link
Member

@brentru brentru left a comment

Choose a reason for hiding this comment

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

This looks good and fixes

@brentru brentru merged commit 0a7b431 into adafruit:master Jun 2, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants