diff options
author | Vadim Yanitskiy <axilirator@gmail.com> | 2019-12-01 18:59:04 +0700 |
---|---|---|
committer | fixeria <axilirator@gmail.com> | 2019-12-01 13:11:42 +0000 |
commit | 7069dfc051d5096e9614a17234646a186de290c9 (patch) | |
tree | 2712a15ee38472a97c0245c523aea39ced4332da | |
parent | 0356e565721d53d4e598b1c6ae7f15f9a89c89b5 (diff) |
trxcon/sched_trx.c: fix potential NULL-pointer dereference
Change-Id: If1ecd9f5a70fa448327c62d38d76c8443b939248
-rw-r--r-- | src/host/trxcon/sched_trx.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/host/trxcon/sched_trx.c b/src/host/trxcon/sched_trx.c index 37d1acf6..eb6f3dc0 100644 --- a/src/host/trxcon/sched_trx.c +++ b/src/host/trxcon/sched_trx.c @@ -264,6 +264,8 @@ int sched_trx_configure_ts(struct trx_instance *trx, int tn, /* Choose proper multiframe layout */ ts->mf_layout = sched_mframe_layout(config, tn); + if (!ts->mf_layout) + return -EINVAL; if (ts->mf_layout->chan_config != config) return -EINVAL; |