Commit 1b9bfbb2 authored by Lorenz Huedepohl's avatar Lorenz Huedepohl
Browse files

Fix wrong usage of target as pointer that was tolerated by gfortran

parent ebd48e48
...@@ -265,7 +265,7 @@ module ftimings_node ...@@ -265,7 +265,7 @@ module ftimings_node
type(node_t), pointer :: node type(node_t), pointer :: node
integer :: i integer :: i
type(value_t) :: cur_value, node_value, own_value, below_threshold_value, total_act type(value_t) :: cur_value, node_value, own_value, below_threshold_value, total_act
type(node_t), target :: own_node, threshold_node type(node_t), pointer :: own_node, threshold_node
real(kind=rk) :: threshold_act real(kind=rk) :: threshold_act
logical :: is_sorted_act, print_own, print_threshold logical :: is_sorted_act, print_own, print_threshold
integer :: unit_act integer :: unit_act
...@@ -310,6 +310,7 @@ module ftimings_node ...@@ -310,6 +310,7 @@ module ftimings_node
! sort them in ! sort them in
if (print_own) then if (print_own) then
! insert an "(own)" node ! insert an "(own)" node
allocate(own_node)
own_node%value = own_value own_node%value = own_value
own_node%name = own own_node%name = own
call insert_into_sorted_list(self%firstChild, own_node) call insert_into_sorted_list(self%firstChild, own_node)
...@@ -317,6 +318,7 @@ module ftimings_node ...@@ -317,6 +318,7 @@ module ftimings_node
if (print_threshold) then if (print_threshold) then
! insert a "(below threshold)" node ! insert a "(below threshold)" node
allocate(threshold_node)
threshold_node%value = below_threshold_value threshold_node%value = below_threshold_value
threshold_node%name = below threshold_node%name = below
call insert_into_sorted_list(self%firstChild, threshold_node) call insert_into_sorted_list(self%firstChild, threshold_node)
...@@ -348,9 +350,11 @@ module ftimings_node ...@@ -348,9 +350,11 @@ module ftimings_node
! remove inserted dummy nodes again ! remove inserted dummy nodes again
if (print_own) then if (print_own) then
call remove_from_list(self%firstChild, own_node) call remove_from_list(self%firstChild, own_node)
deallocate(own_node)
endif endif
if (print_threshold) then if (print_threshold) then
call remove_from_list(self%firstChild, threshold_node) call remove_from_list(self%firstChild, threshold_node)
deallocate(threshold_node)
endif endif
endif endif
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment