Changeset ef3a51f in subsurface


Ignore:
Timestamp:
Dec 10, 2013, 6:13:30 PM (4 years ago)
Author:
Dirk Hohndel <dirk@…>
Branches:
Mtest, android_test, dcDownload, foratdotde, gitMerge, gitdebug, gitpictures, ios, master, mergeKirigamiPort, pictimeshift, resolutionIndependence, spinner, testTomaz, testing, v4.0-branch, v4.0.3-branch, v4.2-branch, v4.4-branch, v4.5-branch
Children:
511f8b8
Parents:
d0c7b3b
git-author:
Anton Lundin <glance@…> (12/10/13 15:53:29)
git-committer:
Dirk Hohndel <dirk@…> (12/10/13 18:13:30)
Message:

Plug potential memory leak in process_raw_buffer

Free temporary buffer before returning.

Signed-off-by: Anton Lundin <glance@…>
Signed-off-by: Dirk Hohndel <dirk@…>

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uemis-downloader.c

    r7ba5566 ref3a51f  
    645645                log = TRUE;
    646646                tp = next_token(&bp);
    647                 if (strcmp(tp,"1.0") != 0)
     647                if (strcmp(tp,"1.0") != 0) {
     648                        free(buf);
    648649                        return;
     650                }
    649651        } else if (strcmp(tp, "dive") == 0) {
    650652                /* this is dive detail */
    651653                tp = next_token(&bp);
    652                 if (strcmp(tp,"1.0") != 0)
     654                if (strcmp(tp,"1.0") != 0) {
     655                        free(buf);
    653656                        return;
     657                }
    654658        } else {
    655659                /* don't understand the buffer */
     660                free(buf);
    656661                return;
    657662        }
Note: See TracChangeset for help on using the changeset viewer.