IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Jun 23, 2004, 1:00:17 PM (22 years ago)
Author:
desonia
Message:

Changed the means of deallocation of memory. ps_Alloc now registers an optional free function to handle any additional processing of a memory object.

Location:
trunk/psLib/test/collections
Files:
36 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/test/collections/builddir/tst_psBitSet_01.d

    r1004 r1073  
    33  ../../include/psTrace.h ../../include/psAbort.h ../../include/psError.h \
    44  ../../include/psString.h ../../include/psType.h ../../include/psList.h \
    5   ../../include/psVector.h ../../include/psHash.h ../../include/psImage.h \
     5  ../../include/psVector.h ../../include/psHash.h \
     6  ../../include/psScalar.h ../../include/psImage.h \
    67  ../../include/psBitSet.h ../../include/psSort.h ../../include/psStats.h \
    7   ../../include/psMatrix.h ../../include/psFFT.h \
    8   ../../include/psImageIO.h ../../include/psTest.h
     8  ../../include/psMatrix.h ../../include/psMatrixVectorArithmetic.h \
     9  ../../include/psFFT.h ../../include/psImageIO.h ../../include/psTest.h
  • trunk/psLib/test/collections/builddir/tst_psBitSet_02.d

    r1004 r1073  
    33  ../../include/psTrace.h ../../include/psAbort.h ../../include/psError.h \
    44  ../../include/psString.h ../../include/psType.h ../../include/psList.h \
    5   ../../include/psVector.h ../../include/psHash.h ../../include/psImage.h \
     5  ../../include/psVector.h ../../include/psHash.h \
     6  ../../include/psScalar.h ../../include/psImage.h \
    67  ../../include/psBitSet.h ../../include/psSort.h ../../include/psStats.h \
    7   ../../include/psMatrix.h ../../include/psFFT.h \
    8   ../../include/psImageIO.h ../../include/psTest.h
     8  ../../include/psMatrix.h ../../include/psMatrixVectorArithmetic.h \
     9  ../../include/psFFT.h ../../include/psImageIO.h ../../include/psTest.h
  • trunk/psLib/test/collections/builddir/tst_psBitSet_03.d

    r1004 r1073  
    33  ../../include/psTrace.h ../../include/psAbort.h ../../include/psError.h \
    44  ../../include/psString.h ../../include/psType.h ../../include/psList.h \
    5   ../../include/psVector.h ../../include/psHash.h ../../include/psImage.h \
     5  ../../include/psVector.h ../../include/psHash.h \
     6  ../../include/psScalar.h ../../include/psImage.h \
    67  ../../include/psBitSet.h ../../include/psSort.h ../../include/psStats.h \
    7   ../../include/psMatrix.h ../../include/psFFT.h \
    8   ../../include/psImageIO.h ../../include/psTest.h
     8  ../../include/psMatrix.h ../../include/psMatrixVectorArithmetic.h \
     9  ../../include/psFFT.h ../../include/psImageIO.h ../../include/psTest.h
  • trunk/psLib/test/collections/builddir/tst_psBitSet_04.d

    r1004 r1073  
    33  ../../include/psTrace.h ../../include/psAbort.h ../../include/psError.h \
    44  ../../include/psString.h ../../include/psType.h ../../include/psList.h \
    5   ../../include/psVector.h ../../include/psHash.h ../../include/psImage.h \
     5  ../../include/psVector.h ../../include/psHash.h \
     6  ../../include/psScalar.h ../../include/psImage.h \
    67  ../../include/psBitSet.h ../../include/psSort.h ../../include/psStats.h \
    7   ../../include/psMatrix.h ../../include/psFFT.h \
    8   ../../include/psImageIO.h ../../include/psTest.h
     8  ../../include/psMatrix.h ../../include/psMatrixVectorArithmetic.h \
     9  ../../include/psFFT.h ../../include/psImageIO.h ../../include/psTest.h
  • trunk/psLib/test/collections/builddir/tst_psBitSet_05.d

    r1004 r1073  
    33  ../../include/psTrace.h ../../include/psAbort.h ../../include/psError.h \
    44  ../../include/psString.h ../../include/psType.h ../../include/psList.h \
    5   ../../include/psVector.h ../../include/psHash.h ../../include/psImage.h \
     5  ../../include/psVector.h ../../include/psHash.h \
     6  ../../include/psScalar.h ../../include/psImage.h \
    67  ../../include/psBitSet.h ../../include/psSort.h ../../include/psStats.h \
    7   ../../include/psMatrix.h ../../include/psFFT.h \
    8   ../../include/psImageIO.h ../../include/psTest.h
     8  ../../include/psMatrix.h ../../include/psMatrixVectorArithmetic.h \
     9  ../../include/psFFT.h ../../include/psImageIO.h ../../include/psTest.h
  • trunk/psLib/test/collections/builddir/tst_psBitSet_06.d

    r1004 r1073  
    33  ../../include/psTrace.h ../../include/psAbort.h ../../include/psError.h \
    44  ../../include/psString.h ../../include/psType.h ../../include/psList.h \
    5   ../../include/psVector.h ../../include/psHash.h ../../include/psImage.h \
     5  ../../include/psVector.h ../../include/psHash.h \
     6  ../../include/psScalar.h ../../include/psImage.h \
    67  ../../include/psBitSet.h ../../include/psSort.h ../../include/psStats.h \
    7   ../../include/psMatrix.h ../../include/psFFT.h \
    8   ../../include/psImageIO.h ../../include/psTest.h
     8  ../../include/psMatrix.h ../../include/psMatrixVectorArithmetic.h \
     9  ../../include/psFFT.h ../../include/psImageIO.h ../../include/psTest.h
  • trunk/psLib/test/collections/builddir/tst_psImage.d

    r1004 r1073  
    33  ../../include/psTrace.h ../../include/psAbort.h ../../include/psError.h \
    44  ../../include/psString.h ../../include/psType.h ../../include/psList.h \
    5   ../../include/psVector.h ../../include/psHash.h ../../include/psImage.h \
     5  ../../include/psVector.h ../../include/psHash.h \
     6  ../../include/psScalar.h ../../include/psImage.h \
    67  ../../include/psBitSet.h ../../include/psSort.h ../../include/psStats.h \
    7   ../../include/psMatrix.h ../../include/psFFT.h \
    8   ../../include/psImageIO.h
     8  ../../include/psMatrix.h ../../include/psMatrixVectorArithmetic.h \
     9  ../../include/psFFT.h ../../include/psImageIO.h
  • trunk/psLib/test/collections/builddir/tst_psList.d

    r1004 r1073  
    33  ../../include/psTrace.h ../../include/psAbort.h ../../include/psError.h \
    44  ../../include/psString.h ../../include/psType.h ../../include/psList.h \
    5   ../../include/psVector.h ../../include/psHash.h ../../include/psImage.h \
     5  ../../include/psVector.h ../../include/psHash.h \
     6  ../../include/psScalar.h ../../include/psImage.h \
    67  ../../include/psBitSet.h ../../include/psSort.h ../../include/psStats.h \
    7   ../../include/psMatrix.h ../../include/psFFT.h \
    8   ../../include/psImageIO.h
     8  ../../include/psMatrix.h ../../include/psMatrixVectorArithmetic.h \
     9  ../../include/psFFT.h ../../include/psImageIO.h
  • trunk/psLib/test/collections/builddir/tst_psSort_01.d

    r1004 r1073  
    33  ../../include/psTrace.h ../../include/psAbort.h ../../include/psError.h \
    44  ../../include/psString.h ../../include/psType.h ../../include/psList.h \
    5   ../../include/psVector.h ../../include/psHash.h ../../include/psImage.h \
     5  ../../include/psVector.h ../../include/psHash.h \
     6  ../../include/psScalar.h ../../include/psImage.h \
    67  ../../include/psBitSet.h ../../include/psSort.h ../../include/psStats.h \
    7   ../../include/psMatrix.h ../../include/psFFT.h \
    8   ../../include/psImageIO.h ../../include/psTest.h
     8  ../../include/psMatrix.h ../../include/psMatrixVectorArithmetic.h \
     9  ../../include/psFFT.h ../../include/psImageIO.h ../../include/psTest.h
  • trunk/psLib/test/collections/builddir/tst_psSort_02.d

    r1004 r1073  
    33  ../../include/psTrace.h ../../include/psAbort.h ../../include/psError.h \
    44  ../../include/psString.h ../../include/psType.h ../../include/psList.h \
    5   ../../include/psVector.h ../../include/psHash.h ../../include/psImage.h \
     5  ../../include/psVector.h ../../include/psHash.h \
     6  ../../include/psScalar.h ../../include/psImage.h \
    67  ../../include/psBitSet.h ../../include/psSort.h ../../include/psStats.h \
    7   ../../include/psMatrix.h ../../include/psFFT.h \
    8   ../../include/psImageIO.h ../../include/psTest.h
     8  ../../include/psMatrix.h ../../include/psMatrixVectorArithmetic.h \
     9  ../../include/psFFT.h ../../include/psImageIO.h ../../include/psTest.h
  • trunk/psLib/test/collections/builddir/tst_psSort_03.d

    r1004 r1073  
    33  ../../include/psTrace.h ../../include/psAbort.h ../../include/psError.h \
    44  ../../include/psString.h ../../include/psType.h ../../include/psList.h \
    5   ../../include/psVector.h ../../include/psHash.h ../../include/psImage.h \
     5  ../../include/psVector.h ../../include/psHash.h \
     6  ../../include/psScalar.h ../../include/psImage.h \
    67  ../../include/psBitSet.h ../../include/psSort.h ../../include/psStats.h \
    7   ../../include/psMatrix.h ../../include/psFFT.h \
    8   ../../include/psImageIO.h ../../include/psTest.h
     8  ../../include/psMatrix.h ../../include/psMatrixVectorArithmetic.h \
     9  ../../include/psFFT.h ../../include/psImageIO.h ../../include/psTest.h
  • trunk/psLib/test/collections/builddir/tst_psSort_04.d

    r1004 r1073  
    33  ../../include/psTrace.h ../../include/psAbort.h ../../include/psError.h \
    44  ../../include/psString.h ../../include/psType.h ../../include/psList.h \
    5   ../../include/psVector.h ../../include/psHash.h ../../include/psImage.h \
     5  ../../include/psVector.h ../../include/psHash.h \
     6  ../../include/psScalar.h ../../include/psImage.h \
    67  ../../include/psBitSet.h ../../include/psSort.h ../../include/psStats.h \
    7   ../../include/psMatrix.h ../../include/psFFT.h \
    8   ../../include/psImageIO.h ../../include/psTest.h
     8  ../../include/psMatrix.h ../../include/psMatrixVectorArithmetic.h \
     9  ../../include/psFFT.h ../../include/psImageIO.h ../../include/psTest.h
  • trunk/psLib/test/collections/builddir/tst_psVector_01.d

    r1004 r1073  
    33  ../../include/psTrace.h ../../include/psAbort.h ../../include/psError.h \
    44  ../../include/psString.h ../../include/psType.h ../../include/psList.h \
    5   ../../include/psVector.h ../../include/psHash.h ../../include/psImage.h \
     5  ../../include/psVector.h ../../include/psHash.h \
     6  ../../include/psScalar.h ../../include/psImage.h \
    67  ../../include/psBitSet.h ../../include/psSort.h ../../include/psStats.h \
    7   ../../include/psMatrix.h ../../include/psFFT.h \
    8   ../../include/psImageIO.h ../../include/psTest.h
     8  ../../include/psMatrix.h ../../include/psMatrixVectorArithmetic.h \
     9  ../../include/psFFT.h ../../include/psImageIO.h ../../include/psTest.h
  • trunk/psLib/test/collections/builddir/tst_psVector_02.d

    r1004 r1073  
    33  ../../include/psTrace.h ../../include/psAbort.h ../../include/psError.h \
    44  ../../include/psString.h ../../include/psType.h ../../include/psList.h \
    5   ../../include/psVector.h ../../include/psHash.h ../../include/psImage.h \
     5  ../../include/psVector.h ../../include/psHash.h \
     6  ../../include/psScalar.h ../../include/psImage.h \
    67  ../../include/psBitSet.h ../../include/psSort.h ../../include/psStats.h \
    7   ../../include/psMatrix.h ../../include/psFFT.h \
    8   ../../include/psImageIO.h ../../include/psTest.h
     8  ../../include/psMatrix.h ../../include/psMatrixVectorArithmetic.h \
     9  ../../include/psFFT.h ../../include/psImageIO.h ../../include/psTest.h
  • trunk/psLib/test/collections/builddir/tst_psVector_03.d

    r1004 r1073  
    33  ../../include/psTrace.h ../../include/psAbort.h ../../include/psError.h \
    44  ../../include/psString.h ../../include/psType.h ../../include/psList.h \
    5   ../../include/psVector.h ../../include/psHash.h ../../include/psImage.h \
     5  ../../include/psVector.h ../../include/psHash.h \
     6  ../../include/psScalar.h ../../include/psImage.h \
    67  ../../include/psBitSet.h ../../include/psSort.h ../../include/psStats.h \
    7   ../../include/psMatrix.h ../../include/psFFT.h \
    8   ../../include/psImageIO.h ../../include/psTest.h
     8  ../../include/psMatrix.h ../../include/psMatrixVectorArithmetic.h \
     9  ../../include/psFFT.h ../../include/psImageIO.h ../../include/psTest.h
  • trunk/psLib/test/collections/tst_psBitSet_01.c

    r965 r1073  
    1717 *  @author  Ross Harman, MHPCC
    1818 *
    19  *  @version $Revision: 1.4 $  $Name: not supported by cvs2svn $
    20  *  @date  $Date: 2004-06-10 00:28:23 $
     19 *  @version $Revision: 1.5 $  $Name: not supported by cvs2svn $
     20 *  @date  $Date: 2004-06-23 23:00:15 $
    2121 *
    2222 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    121121    // Test J - Free psBitSet
    122122    printPositiveTestHeader(stdout, "psBitSet", "Free psBitSet");
    123     psBitSetFree(bs);
     123    psFree(bs);
    124124    psMemCheckLeaks(0, NULL, stdout);
    125125    psMemCheckCorruption(0);
  • trunk/psLib/test/collections/tst_psBitSet_02.c

    r993 r1073  
    1010 *  @author  Ross Harman, MHPCC
    1111 *
    12  *  @version $Revision: 1.4 $  $Name: not supported by cvs2svn $
    13  *  @date  $Date: 2004-06-11 01:39:30 $
     12 *  @version $Revision: 1.5 $  $Name: not supported by cvs2svn $
     13 *  @date  $Date: 2004-06-23 23:00:15 $
    1414 *
    1515 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    6363    // Test C - Free psBitSets
    6464    printPositiveTestHeader(stdout, "psBitSet", "Free psBitSets");
    65     psBitSetFree(bs1);
    66     psBitSetFree(bs2);
    67     psBitSetFree(outbs);
     65    psFree(bs1);
     66    psFree(bs2);
     67    psFree(outbs);
    6868    psMemCheckLeaks(0, NULL, stdout);
    6969    int nBad = psMemCheckCorruption(0);
  • trunk/psLib/test/collections/tst_psBitSet_03.c

    r994 r1073  
    1010 *  @author  Ross Harman, MHPCC
    1111 *
    12  *  @version $Revision: 1.5 $  $Name: not supported by cvs2svn $
    13  *  @date  $Date: 2004-06-11 01:40:45 $
     12 *  @version $Revision: 1.6 $  $Name: not supported by cvs2svn $
     13 *  @date  $Date: 2004-06-23 23:00:15 $
    1414 *
    1515 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    6363    // Test C - Free psBitSets
    6464    printPositiveTestHeader(stdout, "psBitSet", "Free psBitSets");
    65     psBitSetFree(bs1);
    66     psBitSetFree(bs2);
    67     psBitSetFree(outbs);
     65    psFree(bs1);
     66    psFree(bs2);
     67    psFree(outbs);
    6868    psMemCheckLeaks(0, NULL, stdout);
    6969    int nBad = psMemCheckCorruption(0);
  • trunk/psLib/test/collections/tst_psBitSet_04.c

    r995 r1073  
    1010 *  @author  Ross Harman, MHPCC
    1111 *
    12  *  @version $Revision: 1.4 $  $Name: not supported by cvs2svn $
    13  *  @date  $Date: 2004-06-11 01:46:02 $
     12 *  @version $Revision: 1.5 $  $Name: not supported by cvs2svn $
     13 *  @date  $Date: 2004-06-23 23:00:15 $
    1414 *
    1515 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    6363    // Test C - Free psBitSets
    6464    printPositiveTestHeader(stdout, "psBitSet", "Free psBitSets");
    65     psBitSetFree(bs1);
    66     psBitSetFree(bs2);
    67     psBitSetFree(outbs);
     65    psFree(bs1);
     66    psFree(bs2);
     67    psFree(outbs);
    6868    psMemCheckLeaks(0, NULL, stdout);
    6969    int nBad = psMemCheckCorruption(0);
  • trunk/psLib/test/collections/tst_psBitSet_05.c

    r965 r1073  
    1010 *  @author  Ross Harman, MHPCC
    1111 *
    12  *  @version $Revision: 1.4 $  $Name: not supported by cvs2svn $
    13  *  @date  $Date: 2004-06-10 00:28:36 $
     12 *  @version $Revision: 1.5 $  $Name: not supported by cvs2svn $
     13 *  @date  $Date: 2004-06-23 23:00:15 $
    1414 *
    1515 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    4848    // Test C - Free psBitSets
    4949    printPositiveTestHeader(stdout, "psBitSet", "Free psBitSets");
    50     psBitSetFree(bs1);
    51     psBitSetFree(bs2);
    52     psBitSetFree(outbs);
     50    psFree(bs1);
     51    psFree(bs2);
     52    psFree(outbs);
    5353    psMemCheckLeaks(0, NULL, stdout);
    5454    int nBad = psMemCheckCorruption(0);
  • trunk/psLib/test/collections/tst_psBitSet_06.c

    r965 r1073  
    1212 *  @author  Ross Harman, MHPCC
    1313 *
    14  *  @version $Revision: 1.6 $  $Name: not supported by cvs2svn $
    15  *  @date  $Date: 2004-06-10 00:28:43 $
     14 *  @version $Revision: 1.7 $  $Name: not supported by cvs2svn $
     15 *  @date  $Date: 2004-06-23 23:00:15 $
    1616 *
    1717 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    5555    printFooter(stdout, "psBitSet", "Create negative size bitset", true);
    5656
    57 
    58     // Test D - Attempt to free null BitSet
    59     printNegativeTestHeader(stdout,"psBitSet", "Attempt to free null BitSet",
    60                             "Null psBitSet for inBitSet argument", 0);
    61     psBitSetFree(NULL);
    62     printFooter(stdout, "psBitSet", "Attempt to free null BitSet", true);
    63 
    64 
    6557    // Test E - Free psBitSets
    6658    printPositiveTestHeader(stdout, "psBitSet", "Free psBitSets");
    67     psBitSetFree(bs1);
    68     psBitSetFree(bs2);
    69     psBitSetFree(outbs);
     59    psFree(bs1);
     60    psFree(bs2);
     61    psFree(outbs);
    7062    psMemCheckLeaks(0, NULL, stdout);
    7163    int nBad = psMemCheckCorruption(0);
  • trunk/psLib/test/collections/tst_psList.c

    r1033 r1073  
    66 *  @author Robert DeSonia, MHPCC
    77 *
    8  *  @version $Revision: 1.10 $ $Name: not supported by cvs2svn $
    9  *  @date $Date: 2004-06-14 23:03:43 $
     8 *  @version $Revision: 1.11 $ $Name: not supported by cvs2svn $
     9 *  @date $Date: 2004-06-23 23:00:15 $
    1010 *
    1111 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    7878    }
    7979
    80     psListFree(list,NULL);
     80    psFree(list);
    8181
    8282    list = psListAlloc(data);
     
    108108
    109109
    110     psListFree(list,PS_FREE);
     110    psFree(list);
     111
     112    psFree(data);
    111113
    112114    return 0;
     
    283285    }
    284286
    285     psListFree(list, PS_FREE);
     287    psFree(list);
    286288
    287289    return 0;
     
    339341    *data = 0;
    340342    list = psListAlloc(data);
     343    psFree(data);
    341344
    342345    data = psAlloc(sizeof(int));
    343346    *data = 1;
    344347    list = psListAdd(list,data,PS_LIST_TAIL);
     348    psFree(data);
    345349
    346350    data = psAlloc(sizeof(int));
    347351    *data = 2;
    348352    list = psListAdd(list,data,PS_LIST_TAIL);
     353    psFree(data);
    349354
    350355    data = psAlloc(sizeof(int));
    351356    *data = 3;
    352357    list = psListAdd(list,data,PS_LIST_TAIL);
     358    psFree(data);
    353359
    354360    //  2. which>0 and which<list.n.
     
    404410    }
    405411
    406     psListFree(list,PS_FREE);
     412    psFree(list);
    407413
    408414    return 0;
     
    637643    }
    638644
    639     psListFree(list,PS_FREE);
     645    psFree(list);
    640646
    641647    return 0;
     
    691697    }
    692698
    693     psVectorFree(vec);
    694     psListFree(list,PS_FREE);
     699    psFree(vec);
     700    psFree(list);
    695701
    696702    // test vector -> dlist
     
    729735    }
    730736
    731     psVectorFree(vec);
    732     psListFree(list,PS_FREE);
     737    psFree(vec);
     738    psFree(list);
    733739
    734740    // now, make sure if input vector/list is NULL, output is NULL
     
    755761        return 1;
    756762    }
    757     psVectorFree(vec);
    758     psListFree(list,PS_FREE);
     763    psFree(vec);
     764    psFree(list);
    759765
    760766    list = psListAlloc(NULL);
     
    765771        return 1;
    766772    }
    767     psVectorFree(vec);
    768     psListFree(list,PS_FREE);
     773    psFree(vec);
     774    psFree(list);
    769775
    770776    return 0;
     
    895901    }
    896902
    897     psListFree(list,PS_FREE);
     903    psFree(list);
    898904
    899905    return 0;
     
    938944    */
    939945
    940     psListFree(list,NULL);
     946    psFree(list);
    941947
    942948    /*
  • trunk/psLib/test/collections/tst_psSort_01.c

    r988 r1073  
    1010 *  @author  Ross Harman, MHPCC
    1111 *
    12  *  @version $Revision: 1.6 $  $Name: not supported by cvs2svn $
    13  *  @date  $Date: 2004-06-10 23:14:22 $
     12 *  @version $Revision: 1.7 $  $Name: not supported by cvs2svn $
     13 *  @date  $Date: 2004-06-23 23:00:15 $
    1414 *
    1515 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    7171    // Test D - Free float vectors
    7272    printPositiveTestHeader(stdout,"psSort", "Free float vectors");
    73     psVectorFree(in);
    74     psVectorFree(out);
     73    psFree(in);
     74    psFree(out);
    7575    psMemCheckLeaks(0, NULL, stdout);
    7676    int nBad = psMemCheckCorruption(0);
  • trunk/psLib/test/collections/tst_psSort_02.c

    r831 r1073  
    1010 *  @author  Ross Harman, MHPCC
    1111 *
    12  *  @version $Revision: 1.5 $  $Name: not supported by cvs2svn $
    13  *  @date  $Date: 2004-06-02 23:29:29 $
     12 *  @version $Revision: 1.6 $  $Name: not supported by cvs2svn $
     13 *  @date  $Date: 2004-06-23 23:00:15 $
    1414 *
    1515 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    5555    // Test C - Free vectors
    5656    printPositiveTestHeader(stdout,"psSort", "Free vectors");
    57     psVectorFree(in);
    58     psVectorFree(out);
     57    psFree(in);
     58    psFree(out);
    5959    psMemCheckLeaks(0, NULL, stdout);
    6060    int nBad = psMemCheckCorruption(0);
  • trunk/psLib/test/collections/tst_psSort_03.c

    r831 r1073  
    1010 *  @author  Ross Harman, MHPCC
    1111 *
    12  *  @version $Revision: 1.5 $  $Name: not supported by cvs2svn $
    13  *  @date  $Date: 2004-06-02 23:29:29 $
     12 *  @version $Revision: 1.6 $  $Name: not supported by cvs2svn $
     13 *  @date  $Date: 2004-06-23 23:00:15 $
    1414 *
    1515 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    4949    // Test C - Free float vectors
    5050    printPositiveTestHeader(stdout,"psSort", "Free float vectors");
    51     psVectorFree(in);
    52     psVectorFree(out);
     51    psFree(in);
     52    psFree(out);
    5353    psMemCheckLeaks(0, NULL, stdout);
    5454    int nBad = psMemCheckCorruption(0);
  • trunk/psLib/test/collections/tst_psSort_04.c

    r988 r1073  
    99 *  @author  Ross Harman, MHPCC
    1010 *
    11  *  @version $Revision: 1.6 $  $Name: not supported by cvs2svn $
    12  *  @date  $Date: 2004-06-10 23:14:22 $
     11 *  @version $Revision: 1.7 $  $Name: not supported by cvs2svn $
     12 *  @date  $Date: 2004-06-23 23:00:15 $
    1313 *
    1414 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    3333    // Test B - Free vectors
    3434    printPositiveTestHeader(stdout, "psSort", "Free vectors");
    35     psVectorFree(goodOut);
     35    psFree(goodOut);
    3636    psMemCheckLeaks(0, NULL, stdout);
    3737    int nBad = psMemCheckCorruption(0);
  • trunk/psLib/test/collections/tst_psVector_01.c

    r972 r1073  
    1414 *  @author  Ross Harman, MHPCC
    1515 *
    16  *  @version $Revision: 1.7 $  $Name: not supported by cvs2svn $
    17  *  @date  $Date: 2004-06-10 01:50:43 $
     16 *  @version $Revision: 1.8 $  $Name: not supported by cvs2svn $
     17 *  @date  $Date: 2004-06-23 23:00:15 $
    1818 *
    1919 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    7979    // Test E - Free S32 vector
    8080    printPositiveTestHeader(stdout, "psVector", "Free S32 vector");
    81     psVectorFree(psVec);
     81    psFree(psVec);
    8282    psMemCheckLeaks(0, NULL, stdout);
    8383    int nBad = psMemCheckCorruption(0);
  • trunk/psLib/test/collections/tst_psVector_02.c

    r831 r1073  
    1212 *  @author  Ross Harman, MHPCC
    1313 *
    14  *  @version $Revision: 1.3 $  $Name: not supported by cvs2svn $
    15  *  @date  $Date: 2004-06-02 23:29:29 $
     14 *  @version $Revision: 1.4 $  $Name: not supported by cvs2svn $
     15 *  @date  $Date: 2004-06-23 23:00:15 $
    1616 *
    1717 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    102102    // Test E - Free void pointer vector
    103103    printPositiveTestHeader(stdout, "psVector", "Free void pointer vector");
    104     psVectorElementFree(psVec, NULL);
    105     psVectorFree(psVec);
     104    psVectorElementFree(psVec);
     105    psFree(psVec);
    106106    for(int i = 0; i < 10; i++) {
    107107        psFree(mySt[i]);
  • trunk/psLib/test/collections/tst_psVector_03.c

    r867 r1073  
    1212 *  @author  Ross Harman, MHPCC
    1313 *
    14  *  @version $Revision: 1.4 $  $Name: not supported by cvs2svn $
    15  *  @date  $Date: 2004-06-04 19:51:49 $
     14 *  @version $Revision: 1.5 $  $Name: not supported by cvs2svn $
     15 *  @date  $Date: 2004-06-23 23:00:15 $
    1616 *
    1717 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    2828}
    2929testStruct;
    30 
    31 static void freeData(void *data)
    32 {
    33     psFree(data);
    34 }
    35 
    3630
    3731int main(int argc,
     
    5953        psVec->data.PTR[i] = ts;
    6054        psVec->n++;
    61         psMemIncrRefCounter(ts);
    6255    }
    6356
     
    8275        psVec->data.PTR[i] = ts;
    8376        psVec->n++;
    84         psMemIncrRefCounter(ts);
    8577    }
    8678    for(int i = 0; i < 10; i++) {
     
    9284    printFooter(stdout, "psVector", "Reallocate void pointer vector bigger", true);
    9385
    94 
    9586    // Test D - Reallocate void pointer vector smaller
    9687    printPositiveTestHeader(stdout,"psVector","Reallocate void pointer vector smaller");
    97     psVec = psVectorRealloc(3, psVec);
     88    psVec = psVectorRealloc(3, psVec); // this also frees the elements trimmed
    9889    for(int i = 0; i < 3; i++) {
    9990        testStruct *ts = (testStruct*)psVec->data.PTR[i];
     
    109100
    110101    // Free void pointer array struct and its 3 internal elements
    111     psVectorElementFree(psVec, freeData);
    112     psVectorFree(psVec);
     102    psFree(psVec);
    113103
    114     // Free 7 elements manually that were lost after array was reallocated smaller
    115     for(int i = 3; i < 10; i++) {
    116         psFree(mySt[i]);
     104    if (psMemCheckLeaks(0, NULL, stdout) != 0) {
     105        psAbort(__func__,"memory leaks");
    117106    }
    118     psMemCheckLeaks(0, NULL, stdout);
    119107    int nBad = psMemCheckCorruption(0);
    120108    if(nBad) {
  • trunk/psLib/test/collections/verified/tst_psBitSet_01.stderr

    r1018 r1073  
    1  <DATE> <TIME> <HOST> |E|   psBitSetTest| : Line 140 - Bit position too small: -4
    2  <DATE> <TIME> <HOST> |E|   psBitSetTest| : Line 143 - Bit position too large: 200
    3  <DATE> <TIME> <HOST> |E|   psBitSetTest| : Line 137 - Null psBitSet for inBitSet argument
    4  <DATE> <TIME> <HOST> |E|    psBitSetSet| : Line 118 - Bit position too small: -4
    5  <DATE> <TIME> <HOST> |E|    psBitSetSet| : Line 121 - Bit position too large: 200
    6  <DATE> <TIME> <HOST> |E|    psBitSetSet| : Line 115 - Null psBitSet for inBitSet argument
     1 <DATE> <TIME> <HOST> |E|   psBitSetTest| : Line 142 - Bit position too small: -4
     2 <DATE> <TIME> <HOST> |E|   psBitSetTest| : Line 145 - Bit position too large: 200
     3 <DATE> <TIME> <HOST> |E|   psBitSetTest| : Line 139 - Null psBitSet for inBitSet argument
     4 <DATE> <TIME> <HOST> |E|    psBitSetSet| : Line 120 - Bit position too small: -4
     5 <DATE> <TIME> <HOST> |E|    psBitSetSet| : Line 123 - Bit position too large: 200
     6 <DATE> <TIME> <HOST> |E|    psBitSetSet| : Line 117 - Null psBitSet for inBitSet argument
  • trunk/psLib/test/collections/verified/tst_psBitSet_05.stderr

    r1018 r1073  
    1  <DATE> <TIME> <HOST> |E|     psBitSetOp| : Line 187 - psBitSet sizes not the same
     1 <DATE> <TIME> <HOST> |E|     psBitSetOp| : Line 189 - psBitSet sizes not the same
  • trunk/psLib/test/collections/verified/tst_psBitSet_06.stderr

    r1018 r1073  
    1  <DATE> <TIME> <HOST> |E|     psBitSetOp| : Line 214 - Invalid psBitMask binary operation: ZZXOR
    2  <DATE> <TIME> <HOST> |E|  psBitSetAlloc| : Line 84 - Allocation size must be > 0: size = -4
    3  <DATE> <TIME> <HOST> |E|   psBitSetFree| : Line 103 - Null psBitSet for inBitSet argument
     1 <DATE> <TIME> <HOST> |E|     psBitSetOp| : Line 216 - Invalid psBitMask binary operation: ZZXOR
     2 <DATE> <TIME> <HOST> |E|  psBitSetAlloc| : Line 86 - Allocation size must be > 0: size = -4
  • trunk/psLib/test/collections/verified/tst_psBitSet_06.stdout

    r1041 r1073  
    3535/***************************** TESTPOINT ******************************************\
    3636*             TestFile: tst_psBitSet_06.c                                          *
    37 *            TestPoint: psBitSet{Attempt to free null BitSet}                      *
    38 *             TestType: Negative                                                   *
    39 *    ExpectedErrorText: Null psBitSet for inBitSet argument                        *
    40 *  ExpectedStatusValue: 0                                                          *
    41 \**********************************************************************************/
    42 
    43 
    44 ---> TESTPOINT PASSED (psBitSet{Attempt to free null BitSet} | tst_psBitSet_06.c)
    45 
    46 /***************************** TESTPOINT ******************************************\
    47 *             TestFile: tst_psBitSet_06.c                                          *
    4837*            TestPoint: psBitSet{Free psBitSets}                                   *
    4938*             TestType: Positive                                                   *
  • trunk/psLib/test/collections/verified/tst_psList.stderr

    r1034 r1073  
    3030
    3131 <DATE> <TIME> <HOST> |I|    testListGet|Following should be an error
    32  <DATE> <TIME> <HOST> |E|listSetIterator|Unexpected null pointer for psList parameter (psList.c:264).
     32 <DATE> <TIME> <HOST> |E|listSetIterator|Unexpected null pointer for psList parameter (psList.c:262).
    3333
    3434---> TESTPOINT PASSED (psList{489-testListGet} | tst_psList.c)
     
    7070 <DATE> <TIME> <HOST> |I|testListIterato| psListSetIterator/psListGetNext/psListGetPrev shall move the list cursor to the specified location
    7171 <DATE> <TIME> <HOST> |I|testListIterato|Following should error with 'Unexpected null pointer'
    72  <DATE> <TIME> <HOST> |E|listSetIterator|Unexpected null pointer for psList parameter (psList.c:264).
     72 <DATE> <TIME> <HOST> |E|listSetIterator|Unexpected null pointer for psList parameter (psList.c:262).
    7373 <DATE> <TIME> <HOST> |I|testListIterato|Following should error with 'Can't move to an unknown position.'
    7474 <DATE> <TIME> <HOST> |E|listSetIterator|Can't move to an unknown position.  Not moving the iterator position.
  • trunk/psLib/test/collections/verified/tst_psSort_03.stderr

    r1018 r1073  
    1  <DATE> <TIME> <HOST> |E|         psSort| : Line 136 - Input and output vector sizes are not equal: in=5 out=6
     1 <DATE> <TIME> <HOST> |E|         psSort| : Line 137 - Input and output vector sizes are not equal: in=5 out=6
  • trunk/psLib/test/collections/verified/tst_psSort_04.stderr

    r1018 r1073  
    1  <DATE> <TIME> <HOST> |E|         psSort| : Line 118 - Null input vector
     1 <DATE> <TIME> <HOST> |E|         psSort| : Line 119 - Null input vector
Note: See TracChangeset for help on using the changeset viewer.