displayio: Fix matrixportal crash
An RGBMatrix has no bus and no bus_free method. It is always possible to refresh the display. This was not a problem before, but the fix I suggested (#3449) added a call to core_bus_free when a FramebufferDisplay was being refreshed. This was not caught during testing. This is a band-aid fix and it brings to light a second problem in which a SharpDisplay + FrameBuffer will not have a 'bus' object, and yet does operate using a shared SPI bus. This kind of display will need a "bus-free" like function to be added, or it can have problems like #3309.
This commit is contained in:
parent
e114b5ab54
commit
b1592564b2
1 changed files with 1 additions and 1 deletions
|
|
@ -197,7 +197,7 @@ bool displayio_display_core_get_dither(displayio_display_core_t* self){
|
|||
}
|
||||
|
||||
bool displayio_display_core_bus_free(displayio_display_core_t *self) {
|
||||
return self->bus_free(self->bus);
|
||||
return !self->bus || self->bus_free(self->bus);
|
||||
}
|
||||
|
||||
bool displayio_display_core_begin_transaction(displayio_display_core_t* self) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue