segmentation fault in cause of empty list
This commit is contained in:
parent
94695f773e
commit
680c9e11d4
|
@ -351,7 +351,7 @@ end subroutine finalize
|
||||||
|
|
||||||
!--------------------------------------------------------------------------------------------------
|
!--------------------------------------------------------------------------------------------------
|
||||||
!> @brief cleans entire array of linke lists
|
!> @brief cleans entire array of linke lists
|
||||||
!> @details called when variable goes out of scope.
|
!> @details called when variable goes out of scope and deallocates the list at each array entry
|
||||||
!--------------------------------------------------------------------------------------------------
|
!--------------------------------------------------------------------------------------------------
|
||||||
subroutine finalizeArray(this)
|
subroutine finalizeArray(this)
|
||||||
|
|
||||||
|
@ -361,11 +361,11 @@ subroutine finalizeArray(this)
|
||||||
type(tPartitionedStringList), pointer :: temp ! bug in Gfortran?
|
type(tPartitionedStringList), pointer :: temp ! bug in Gfortran?
|
||||||
|
|
||||||
do i=1, size(this)
|
do i=1, size(this)
|
||||||
!if (associated(this(i)%next)) then
|
if (associated(this(i)%next)) then
|
||||||
temp => this(i)%next
|
temp => this(i)%next
|
||||||
!deallocate(this(i)) !internal compiler error: in gfc_build_final_call, at fortran/trans.c:975
|
!deallocate(this(i)) !internal compiler error: in gfc_build_final_call, at fortran/trans.c:975
|
||||||
deallocate(temp)
|
deallocate(temp)
|
||||||
!endif
|
endif
|
||||||
enddo
|
enddo
|
||||||
|
|
||||||
end subroutine finalizeArray
|
end subroutine finalizeArray
|
||||||
|
|
Loading…
Reference in New Issue