File tree Expand file tree Collapse file tree
shared-module/framebufferio Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -219,12 +219,14 @@ STATIC void _refresh_display(framebufferio_framebufferdisplay_obj_t* self) {
219219 displayio_display_core_start_refresh (& self -> core );
220220 self -> framebuffer_protocol -> get_bufinfo (self -> framebuffer , & self -> bufinfo );
221221 const displayio_area_t * current_area = _get_refresh_areas (self );
222- while (current_area != NULL ) {
223- _refresh_area (self , current_area );
224- current_area = current_area -> next ;
222+ if (current_area ) {
223+ while (current_area != NULL ) {
224+ _refresh_area (self , current_area );
225+ current_area = current_area -> next ;
226+ }
227+ self -> framebuffer_protocol -> swapbuffers (self -> framebuffer );
225228 }
226229 displayio_display_core_finish_refresh (& self -> core );
227- self -> framebuffer_protocol -> swapbuffers (self -> framebuffer );
228230}
229231
230232void common_hal_framebufferio_framebufferdisplay_set_rotation (framebufferio_framebufferdisplay_obj_t * self , int rotation ){
You can’t perform that action at this time.
0 commit comments