IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Dec 9, 2004, 4:50:16 PM (22 years ago)
Author:
desonia
Message:

Changed psList API for iterators, etc.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/test/astronomy/tst_psMetadata_01.c

    r2607 r2681  
    1818*  @author  Ross Harman, MHPCC
    1919*
    20 *  @version $Revision: 1.16 $  $Name: not supported by cvs2svn $
    21 *  @date  $Date: 2004-12-03 23:19:07 $
     20*  @version $Revision: 1.17 $  $Name: not supported by cvs2svn $
     21*  @date  $Date: 2004-12-10 02:50:15 $
    2222*
    2323*  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    4646    psMetadataItem *entryChild = NULL;
    4747
    48     psListSetIterator(metadataItemList, PS_LIST_HEAD);
    49     entryChild = psListGetCurrent(metadataItemList);
    50     while (entryChild != NULL) {
     48    psListIterator* iter = psListIteratorAlloc(metadataItemList, PS_LIST_HEAD);
     49
     50    while ( (entryChild=psListGetNext(iter)) != NULL) {
    5151        printMetadataItem(entryChild, spaces);
    52         entryChild = psListGetNext(metadataItemList);
    53     }
     52    }
     53
     54    psFree(iter);
     55
    5456}
    5557
Note: See TracChangeset for help on using the changeset viewer.