AP_OSD: prevent startup segfault

This commit is contained in:
Andrew Tridgell 2020-09-01 08:58:57 +10:00
parent 844d2bf7ff
commit 8ca9af72e0

View File

@ -940,7 +940,7 @@ void AP_OSD_Screen::set_backend(AP_OSD_Backend *_backend)
bool AP_OSD_Screen::check_option(uint32_t option)
{
return (osd->options & option) != 0;
return osd?(osd->options & option) != 0 : false;
}
/*