keymaster: avoid deref'ing nullptr
`error` may be null in these cases. Ideally, we shouldn't be storing to
it unconditionally.
Caught by the static analyzer:
> system/keymaster/contexts/soft_attestation_cert.cpp:307:37: warning:
Dereference of null pointer (loaded from variable 'error')
[clang-analyzer-core.NullDereference] >
system/keymaster/contexts/soft_attestation_cert.cpp:311:37: warning:
Dereference of null pointer (loaded from variable 'error')
[clang-analyzer-core.NullDereference]
Bug: None
Test: TreeHugger
Change-Id: Ie3f6d1302c303fa8749083f53b036579f3d81c6d
1 file changed