aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDenis Kenzior <denkenz@gmail.com>2024-02-27 17:02:22 -0600
committerDenis Kenzior <denkenz@gmail.com>2024-02-28 20:59:33 -0600
commit6969749900b38fd35aac449f18441a064e7b4cb3 (patch)
tree4805a7a95b499367e57a4eb6661efedd861b4a7b
parentd6196a4840b9c4231ead79e1d4e72cf97a3d5668 (diff)
downloadofono-6969749900b38fd35aac449f18441a064e7b4cb3.tar.gz
emulator: Check cb isn't NULL before invoking
-rw-r--r--src/emulator.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/emulator.c b/src/emulator.c
index 2d7475988..dd6aebe77 100644
--- a/src/emulator.c
+++ b/src/emulator.c
@@ -1700,7 +1700,8 @@ int ofono_emulator_start_codec_negotiation(struct ofono_emulator *em,
* Report we're done even if we don't have done any
* negotiation as the other side may have to clean up.
*/
- cb(0, data);
+ if (cb)
+ cb(0, data);
/*
* If we didn't received any +BAC during the SLC setup the