Changeset 15346


Ignore:
Timestamp:
04/22/12 12:42:13 (11 years ago)
Author:
gost
Message:

[titan] fix memleak

File:
1 edited

Legend:

Unmodified
Added
Removed
  • titan/titan/titan.c

    r15342 r15346  
    368368        int ret = 0, serviceret = 0, skincheck = 0;
    369369        char* tmpstr = NULL;
     370        unsigned char *mmapfb = NULL;
    370371        struct sigaction sa;
    371372        struct stimerthread *tmpthread = NULL;
     
    534535
    535536        if(lcdskinfb == NULL) {
    536                 unsigned char *mmapfb = malloc(4 * 320 * 240);
     537                mmapfb = malloc(4 * 320 * 240);
    537538                /* dev=999 ist LCD Buffer */
    538539                lcdskinfb = addfb("lcdskinfb", 999, 320, 240, 4, -1, mmapfb, 4 * 320 * 240);
    539                 mmapfb = NULL;
     540                // mmapfb = NULL;
    540541        }
    541542
     
    814815        //subtitlestart();
    815816
     817        if(mmapfb != NULL) {
     818                free(mmapfb); mmapfb=NULL;
     819        }
    816820        debug(1000, "out");
    817821        oshutdown(1, 1);
Note: See TracChangeset for help on using the changeset viewer.