IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Jun 3, 2004, 5:20:08 PM (22 years ago)
Author:
gusciora
Message:

Added memory leak chewcks.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/test/sysUtils/tst_psHash03.c

    r584 r860  
    11/*****************************************************************************
    2     This code tests whether hash tables entries can be removed correctly.
     2    This code will test whether hash tables entries can be removed correctly.
    33 
    44    GUS: Add code to test whether duplicates are handled correctly.
     
    4040    char *myKeys[] = {"ENTRY00", "ENTRY01", "ENTRY02", "ENTRY03", NULL};
    4141    char *myData[] = {"IDA", "IDB", "IDC", "IDD", NULL};
     42    int currentId = psMemGetId();
     43    int memLeaks        = 0;
    4244
    4345    printPositiveTestHeader(stdout,
     
    8284                testStatus);
    8385
     86    psHashFree(myHashTable, NULL);
     87    memLeaks = psMemCheckLeaks(currentId,NULL,NULL);
     88    if (0 != memLeaks) {
     89        psAbort(__func__,"Memory Leaks! (%d leaks)", memLeaks);
     90    }
     91    psMemCheckCorruption(1);
     92
    8493    return (!testStatus);
    8594}
Note: See TracChangeset for help on using the changeset viewer.