-
Notifications
You must be signed in to change notification settings - Fork 4.9k
KW - null pointer checks added #11469
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
KW - null pointer checks added #11469
Conversation
src/sensor.cpp
Outdated
@@ -2,7 +2,7 @@ | |||
// Copyright(c) 2015 Intel Corporation. All Rights Reserved. | |||
|
|||
#include "sensor.h" | |||
|
|||
#include "api.h" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please do not mix api
with internal source code.
This macro is only used on API, and if you search the code you can verify it.
Please use other methods to do so.. if (!...)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK, Done.
Can I leave api usage in the "stream.h" file? I see we have usages of this macro there.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- I still see the include here
- Where do you see a usage of this macro on
stream.h
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, not in the stream.h
, in the rs.cpp
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rs.cpp can include the api.h
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
The "if" statements added
0913c2e
to
6d89576
Compare
The code format was refactored back to what it was before. The api.h include removed.
Tracking on [LRS-696]