Bug with qrad size detected by the test-farm.

This commit is contained in:
Samuel Ponce 2019-11-06 14:09:20 +01:00
parent 0664701b08
commit c8602feb81
1 changed files with 6 additions and 4 deletions

View File

@ -229,11 +229,13 @@
ENDDO
!
IF (maxvalue > nqxq) THEN
!IF (ALLOCATED(qrad)) DEALLOCATE(qrad)
IF (epwread) THEN
ALLOCATE(qrad(maxvalue, nbetam * (nbetam + 1) / 2, lmaxq, nsp), STAT = ierr)
IF (ierr /= 0) CALL errore('elphon_shuffle_wrap', 'Error allocating qrad(maxvalue, nbetam * ', 1)
IF (.NOT. epwread) THEN
DEALLOCATE(qrad, STAT = ierr)
IF (ierr /= 0) CALL errore('elphon_shuffle_wrap', 'Error deallocating qrad', 1)
ENDIF
ALLOCATE(qrad(maxvalue, nbetam * (nbetam + 1) / 2, lmaxq, nsp), STAT = ierr)
IF (ierr /= 0) CALL errore('elphon_shuffle_wrap', 'Error allocating qrad ', 1)
!
qrad(:, :, :, :) = zero
! RM - need to call init_us_1 to re-calculate qrad
CALL init_us_1()