1
1
Fork 0
mirror of https://github.com/QB64Official/qb64.git synced 2024-07-01 09:10:37 +00:00

Merge pull request #149 from SpriggsySpriggs/development

Fixes bug that frees console_image handle in Clear
This commit is contained in:
Fellippe Heitor 2021-03-16 23:44:21 -03:00 committed by GitHub
commit e0d70e4c71
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -18608,7 +18608,7 @@ void sub_put2(int32 i,int64 offset,void *element,int32 passed){
static int32 i;
//note: handles 0 & -1(1) are reserved
for (i=2;i<nextimg;i++){
if (img[i].valid){
if (img[i].valid && i != abs(console_image)){
if ((img[i].flags&IMG_SCREEN)==0){//The SCREEN's pages cannot be freed!
sub__freeimage(-i,1);
}