Fixed clipboard memory leak on shutdown
This commit is contained in:
@@ -24,6 +24,7 @@
|
|||||||
// The high-level video driver subsystem
|
// The high-level video driver subsystem
|
||||||
|
|
||||||
#include "SDL_sysvideo.h"
|
#include "SDL_sysvideo.h"
|
||||||
|
#include "SDL_clipboard_c.h"
|
||||||
#include "SDL_egl_c.h"
|
#include "SDL_egl_c.h"
|
||||||
#include "SDL_surface_c.h"
|
#include "SDL_surface_c.h"
|
||||||
#include "SDL_pixels_c.h"
|
#include "SDL_pixels_c.h"
|
||||||
@@ -4263,6 +4264,8 @@ void SDL_VideoQuit(void)
|
|||||||
SDL_free(_this->displays);
|
SDL_free(_this->displays);
|
||||||
_this->displays = NULL;
|
_this->displays = NULL;
|
||||||
|
|
||||||
|
SDL_CancelClipboardData(_this->clipboard_sequence);
|
||||||
|
|
||||||
if (_this->primary_selection_text) {
|
if (_this->primary_selection_text) {
|
||||||
SDL_free(_this->primary_selection_text);
|
SDL_free(_this->primary_selection_text);
|
||||||
_this->primary_selection_text = NULL;
|
_this->primary_selection_text = NULL;
|
||||||
|
|||||||
Reference in New Issue
Block a user