iNodeDestroy Subroutine

public subroutine iNodeDestroy(List)

Arguments

Type IntentOptional Attributes Name
type(iNode), pointer :: List

Called by

proc~~inodedestroy~~CalledByGraph proc~inodedestroy iNodeDestroy proc~esmf_cfiovarinfodestroy ESMF_CFIOVarInfoDestroy proc~esmf_cfiovarinfodestroy->proc~inodedestroy proc~esmf_cfiodestroy ESMF_CFIODestroy proc~esmf_cfiodestroy->proc~esmf_cfiovarinfodestroy none~find~33 CFIOCollection%find none~find~33->proc~esmf_cfiodestroy proc~mapl_cfiodestroy MAPL_CFIODestroy proc~mapl_cfiodestroy->proc~esmf_cfiodestroy interface~esmf_iodestroy ESMF_ioDestroy interface~esmf_iodestroy->proc~mapl_cfiodestroy proc~mapl_cfiocreatefromfile MAPL_CFIOCreateFromFile proc~mapl_cfiocreatefromfile->none~find~33 proc~mapl_cfioreadbundleread MAPL_CFIOReadBundleRead proc~mapl_cfioreadbundleread->none~find~33

Source Code

   subroutine iNodeDestroy(List)
     type(iNode), pointer :: List, p, q

     if (.not. associated(List)) return
     q => List
     p => List%next
     do while ( associated(p) )  
        if (associated(q)) then
           if (associated(q%intData)) deallocate(q%intData)
           deallocate(q)
        end if
        q => p
        p => p%next
     end do

     if (associated(q)) then 
        if (associated(q%intData)) deallocate(q%intData)
        deallocate(q)
     end if
   end subroutine iNodeDestroy