Skip to content

Commit

Permalink
Merge pull request #22 from a1091150/main
Browse files Browse the repository at this point in the history
Fix segmentation fault after destorying window
  • Loading branch information
jserv authored Jul 28, 2024
2 parents 015045c + fbcbdd8 commit e1892ce
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions backend/sdl.c
Original file line number Diff line number Diff line change
Expand Up @@ -58,12 +58,12 @@ static void _twin_sdl_put_span(twin_coord_t left,

static void _twin_sdl_destroy(twin_screen_t *screen, twin_sdl_t *tx)
{
twin_screen_destroy(screen);

SDL_DestroyTexture(tx->texture);
SDL_DestroyRenderer(tx->render);
SDL_DestroyWindow(tx->win);
SDL_Quit();

twin_screen_destroy(screen);
}

static void twin_sdl_damage(twin_screen_t *screen, twin_sdl_t *tx)
Expand Down

0 comments on commit e1892ce

Please sign in to comment.