OSDN Git Service

[NetworkPolicy]: Fixes the crash issues caused by null pointer.
authorzhangshuxiao <zhangshuxiao@xiaomi.com>
Tue, 9 Aug 2016 10:48:04 +0000 (18:48 +0800)
committerShuxiao Zhang <zhangshuxiao@xiaomi.com>
Wed, 10 Aug 2016 03:49:54 +0000 (03:49 +0000)
commitbad369d63e975b7360693cebd1728765ddc7b924
tree3d3b797ef02ba13ed6d78430040ccc0782ebcc2b
parent5b63231a31dbeafc0dfb260b2ebc52f536dc3441
[NetworkPolicy]: Fixes the crash issues caused by null pointer.

When handleRegisterNetworkAgent in ConnectivityService,
the networkinfo of NetworkAgentInfo will be set to null.
So we need to handle the null pointer of state.networkInfo.

Change-Id: I2a278f1f1b2455057fd2ed323ff4df340c3cbca9
Signed-off-by: zhangshuxiao <zhangshuxiao@xiaomi.com>
services/core/java/com/android/server/net/NetworkPolicyManagerService.java