Commit cdeed598 authored by Matthias Redies's avatar Matthias Redies

handle unallocated arrays

parent c48d873f
......@@ -624,10 +624,12 @@ CONTAINS
integer :: n1, n2
if(.not. allocated(olap) .or. any(shape(olap) /= n_radbasfn)) then
if(allocated(olap)) deallocate(olap)
allocate(olap(n_radbasfn, n_radbasfn), source=0.0)
if(allocated(olap)) then
if(any(shape(olap) /= n_radbasfn)) then
if(.not. allocated(olap)) allocate(olap(n_radbasfn, n_radbasfn), source=0.0)
DO n2 = 1, n_radbasfn
DO n1 = 1, n2
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