Skip to content

Commit

Permalink
bug fix for data corruption #1075
Browse files Browse the repository at this point in the history
  • Loading branch information
edoapra committed Feb 5, 2025
1 parent be63aeb commit 253ba23
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
9 changes: 4 additions & 5 deletions src/nwdft/rt_tddft/headers/rt_tddft.fh
Original file line number Diff line number Diff line change
Expand Up @@ -47,14 +47,13 @@ C

C
C Hardcoded limits to the number of geometries, fields, and
C excitation rules. I think 100 is a sane choice (that is the
C default max number of geoms in nwchem). I chose hardcoded max
C excitation rules. I chose hardcoded max
C numbers since each of these are derived data types, and therefore
C there is no MA routine for allocating them.
C
integer, parameter :: rt_max_geoms = 100
integer, parameter :: rt_max_fields = 100
integer, parameter :: rt_max_excites = 100
integer, parameter :: rt_max_geoms = 200
integer, parameter :: rt_max_fields = 200
integer, parameter :: rt_max_excites = 200



Expand Down
4 changes: 4 additions & 0 deletions src/nwdft/rt_tddft/init/rt_tddft_init_geoms.F
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,10 @@ subroutine rt_tddft_init_geoms (params)

if (ngeom_rtdb .gt. max_geom_rtdb)
$ call errquit(pname//"invalid ngeom_rtdb > max_geom_rtdb",0,0)

if (ngeom_rtdb .gt. rt_max_geoms)
$ call errquit(pname//"invalid ngeom_rtdb > rt_max_geoms",
G ngeom_rtdb, 0)

if (.not. rtdb_cget (params%rtdb,'geometry:names',
$ ngeom_rtdb,names_rtdb))
Expand Down

0 comments on commit 253ba23

Please sign in to comment.