Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit a4198301 authored by George Burgess IV's avatar George Burgess IV
Browse files

binder: don't dereference NULL

Simply forming a reference to NULL results in undefined behavior
regardless of how the reference is used. Since `outPollFd` and
`errPollFd` are potentially NULL, we should pass them as pointers here.

Caught by clang's static analyzer:
> frameworks/native/libs/binder/UtilsHost.cpp:145:14: warning: Forming
reference to null pointer [clang-analyzer-core.NonNullParamChecker]
> frameworks/native/libs/binder/UtilsHost.cpp:147:14: warning: Forming
reference to null pointer [clang-analyzer-core.NonNullParamChecker]

Bug: None
Test: TreeHugger

Change-Id: Idf8c8291bde0ce0624085afd143096c357246673
parent 9f0e60e6
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment