Skip to content

Commit

Permalink
Fix #27 path length issues
Browse files Browse the repository at this point in the history
  • Loading branch information
pcboy committed May 29, 2024
1 parent 136c1d7 commit 0f8a496
Show file tree
Hide file tree
Showing 160 changed files with 2,078 additions and 2,059 deletions.
8 changes: 4 additions & 4 deletions CSM_Main/CSM.for
Original file line number Diff line number Diff line change
Expand Up @@ -91,11 +91,11 @@ C-----------------------------------------------------------------------
CHARACTER*12 FILEX !,DSCSM,INPUT
CHARACTER*30 FILEB,FILEIO,FILEIOH
CHARACTER*78 MSG(10)
CHARACTER*80 PATHEX
CHARACTER*255 PATHEX
CHARACTER*102 DSSATP
! CHARACTER*120 INPUTX
CHARACTER*120 FILECTL !12/11/08 control file includes path
CHARACTER*120 PATHX
! CHARACTER*255 INPUTX
CHARACTER*255 FILECTL !12/11/08 control file includes path
CHARACTER*255 PATHX
CHARACTER*130 CHARTEST

INTEGER YRDOY,YRSIM,YRPLT,MDATE,YREND,YR,ISIM, YR0, ISIM0
Expand Down
4 changes: 2 additions & 2 deletions InputModule/COMSWI.blk
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@
CHARACTER*25 TITLER
CHARACTER*102 DSSATP
CHARACTER*60 ENAME
CHARACTER*80 PATHSL,PATHWT,PATHCR,PATHGE,PATHPE,PATHEC
CHARACTER*80 PATHWTC, PATHWTG, PATHWTW
CHARACTER*255 PATHSL,PATHWT,PATHCR,PATHGE,PATHPE,PATHEC
CHARACTER*255 PATHWTC, PATHWTG, PATHWTW
INTEGER NSWITCH, DBUG1, DBUG2

COMMON/SWITCH/ISWWAT,ISWNIT,ISWSYM,ISWPHO,ISWPOT,ISWDIS,ICO2,
Expand Down
2 changes: 1 addition & 1 deletion InputModule/INVAR.for
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ C=======================================================================
CHARACTER*6 GNAME(18),VARTY,ECONO
CHARACTER*12 FILEG
CHARACTER*16 VRNAME
CHARACTER*80 PATHGE
CHARACTER*255 PATHGE
CHARACTER*92 FILEGG

INTEGER I,IG,PATHL
Expand Down
2 changes: 1 addition & 1 deletion InputModule/IPCHEM.for
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ C=======================================================================
CHARACTER*6 ERRKEY,FINDCH
CHARACTER*12 FILEX
CHARACTER*42 CHEXTR(NAPPL)
CHARACTER*80 CHARTEST
CHARACTER*255 CHARTEST

INTEGER LNCHE,LUNEXP,ISECT,LINEXP,CDATE(NAPPL),NCHEM
INTEGER ERRNUM,J,IFIND,LN,YRSIM,ICHCOD !,LNSIM
Expand Down
2 changes: 1 addition & 1 deletion InputModule/IPECO.for
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ C=======================================================================
CHARACTER*8 MODEL
CHARACTER*12 FILEE
CHARACTER*16 ECONAM
CHARACTER*80 PATHEC
CHARACTER*255 PATHEC
CHARACTER*92 FILEGC
CHARACTER*255 C255

Expand Down
10 changes: 5 additions & 5 deletions InputModule/IPMAN.for
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ C=======================================================================
CHARACTER*5 IRRCOD(NAPPL),IOFFX,IAMEX
CHARACTER*6 FINDCH,ERRKEY
CHARACTER*12 FILEX
CHARACTER*80 CHARTEST
CHARACTER*255 CHARTEST

INTEGER I, PERM, PERMDOY

Expand Down Expand Up @@ -291,7 +291,7 @@ C=======================================================================
CHARACTER*6 ERRKEY,FINDCH
CHARACTER*12 FILEX
CHARACTER*78 MSG(3)
CHARACTER*80 CHARTEST
CHARACTER*255 CHARTEST
INTEGER LNRES,LUNEXP,ISECT,LINEXP,RESDAY(NAPPL),NRESAP
INTEGER ERRNUM,J,IFIND,LN,NARES,YRSIM,LNSIM,IRESCD
Expand Down Expand Up @@ -497,7 +497,7 @@ C=======================================================================
CHARACTER*5 FERCOD(NAPPL),FOCOD(NAPPL),IFTYPE(NAPPL)
CHARACTER*6 ERRKEY,FINDCH
CHARACTER*12 FILEX
CHARACTER*80 CHARTEST
CHARACTER*255 CHARTEST
INTEGER LUNEXP,LNFER,YRSIM,NFERT,FDAY(NAPPL),IFFTYP,IFFCOD
INTEGER ISECT,LINEXP,ERRNUM,J,IFIND,LN,LNSIM
Expand Down Expand Up @@ -660,7 +660,7 @@ C=======================================================================
CHARACTER*5 HSTG(NAPPL),HCOM(NAPPL),HSIZ(NAPPL)
CHARACTER*6 ERRKEY,FINDCH
CHARACTER*12 FILEX
CHARACTER*80 CHARTEST
CHARACTER*255 CHARTEST
INTEGER LNHAR,LUNEXP,ISECT,LINEXP,HDATE(NAPPL),NHAR
INTEGER ERRNUM,J,IFIND,LN,YRSIM
Expand Down Expand Up @@ -840,7 +840,7 @@ C=======================================================================
CHARACTER*6 ERRKEY,VARNO,FINDCH
CHARACTER*12 FILEX
CHARACTER*16 CNAME
CHARACTER*80 CHARTEST
CHARACTER*255 CHARTEST
PARAMETER (ERRKEY='IPCUL ')
Expand Down
4 changes: 2 additions & 2 deletions InputModule/IPSIM.for
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ C=======================================================================
CHARACTER*16 CROPD
CHARACTER*25 TITSIM
CHARACTER*78 MSG(7)
CHARACTER*120 FILECTL
CHARACTER*255 FILECTL
CHARACTER*128 CHARTEST

INTEGER LNSIM,LUNEXP,ISECT,LINEXP,ISIM,NYRS,NREPSQ,FROP
Expand Down Expand Up @@ -1085,7 +1085,7 @@ C-----------------------------------------------------------------------
CHARACTER*12 FILEX !, DSSATS
CHARACTER*78 MSG(50)
CHARACTER*102 DSSATP, SIMCTR
CHARACTER*120 INPUTX, FILECTL
CHARACTER*255 INPUTX, FILECTL
CHARACTER*128 CHARTEST
INTEGER CTRNO, ERRNUM, FOUND, FROP, I, IFIND, IPX, ISECT, ISIM
Expand Down
8 changes: 4 additions & 4 deletions InputModule/IPSLIN.for
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ C=======================================================================
CHARACTER*6 ERRKEY,FINDCH
CHARACTER*10 PEDON,SLNO
CHARACTER*12 FILEX
CHARACTER*80 CHARTEST
CHARACTER*92 FILEX_P
CHARACTER*255 CHARTEST
CHARACTER*255 FILEX_P

INTEGER L,LN,LUNEXP,NLAYRI,NLAYR,LINEXP,ISECT,LNIC, !,FWY1P,
& YRIC,ERRNUM,IFIND !,YRSIM, YRICYEAR, YR, DOY
Expand Down Expand Up @@ -248,8 +248,8 @@ C=======================================================================
CHARACTER*6 ERRKEY, FINDCH
CHARACTER*10 SLNO, PEDON
CHARACTER*12 FILEX
CHARACTER*80 CHARTEST*80
CHARACTER*92 FILEX_P
CHARACTER*255 CHARTEST*80
CHARACTER*255 FILEX_P

INTEGER LN,LUNEXP,NLAYRI,NLAYR,LINEXP,ISECT,LNSA
INTEGER ERRNUM,SADAT,IFIND,L !,YRSIM
Expand Down
2 changes: 1 addition & 1 deletion InputModule/IPSOIL_Inp.for
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ C=======================================================================
CHARACTER*6 ERRKEY
CHARACTER*12 FILES
CHARACTER*78 MSG(25)
CHARACTER*80 PATHSL
CHARACTER*255 PATHSL
CHARACTER*92 FILESS
CHARACTER*255 C255

Expand Down
2 changes: 1 addition & 1 deletion InputModule/IPTILL.for
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ C=======================================================================
CHARACTER*6 ERRKEY,FINDCH
CHARACTER*12 FILEX
CHARACTER*1 ISWTIL
CHARACTER*80 CHARTEST
CHARACTER*255 CHARTEST

INTEGER LNTIL,LUNEXP,ISECT,LINEXP,TDATE(NAPPL),NTIL
INTEGER ERRNUM,J,IFIND,LN,YRSIM,LNSIM,TIMPLN
Expand Down
2 changes: 1 addition & 1 deletion InputModule/IPVAR.for
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ C=======================================================================
CHARACTER*12 FILEG
CHARACTER*16 VRNAME
CHARACTER*78 MSG(3)
CHARACTER*80 PATHGE
CHARACTER*255 PATHGE
CHARACTER*92 FILEGG
CHARACTER*1000 C360,ATLINE

Expand Down
6 changes: 3 additions & 3 deletions InputModule/MAKEFILEW.f90
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,9 @@ SUBROUTINE MAKEFILEW(LUNEXP,DSSATP,PATHEX,FILEX, &
CHARACTER*5 FINDH
CHARACTER*8 WSTA,FILEW4,FILEX
CHARACTER*12 FILEW,NAMEF, LastFileW
CHARACTER*78 MSG(4)
CHARACTER*80 PATHWT,PATHEX,CHARTEST
CHARACTER*92 FILEWW,FILETMP
CHARACTER*255 MSG(4)
CHARACTER*255 PATHWT,PATHEX,CHARTEST
CHARACTER*255 FILEWW,FILETMP
CHARACTER*102 DSSATP
CHARACTER*255 LINE

Expand Down
4 changes: 2 additions & 2 deletions InputModule/OPGEN.for
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@ C=======================================================================
CHARACTER* 8 MODEL
CHARACTER* 16 CROPD, VRNAME
CHARACTER* 25 TITLET
CHARACTER* 80 PATHEX
CHARACTER*120 WTHSTR
CHARACTER*255 PATHEX
CHARACTER*255 WTHSTR
CHARACTER*1000 ATLINE

INTEGER NYRS,RUN
Expand Down
4 changes: 2 additions & 2 deletions InputModule/OPHEAD.for
Original file line number Diff line number Diff line change
Expand Up @@ -156,9 +156,9 @@ C=======================================================================
CHARACTER*8 MODEL
CHARACTER*16 VRNAME
CHARACTER*25 TITLET
CHARACTER*80 PATHEX
CHARACTER*255 PATHEX
CHARACTER*120 HEADER(100) !Simulation header
CHARACTER*120 WTHSTR
CHARACTER*255 WTHSTR

INTEGER DYNAMIC
INTEGER ICOUNT, I, IDYP,IDYS,IPYRP,IPYRS,NNFERT
Expand Down
2 changes: 1 addition & 1 deletion InputModule/OPTEMPXY2K.for
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ C=======================================================================
CHARACTER*16 VRNAME
CHARACTER*30 FILEIO,FILEIOH
CHARACTER*42 CHEXTR(NAPPL)
CHARACTER*80 PATHEX
CHARACTER*255 PATHEX
CHARACTER*1000 ATLINE

INTEGER NYRS,I,LUNIO,ERRNUM,FROP,YRIC
Expand Down
16 changes: 8 additions & 8 deletions InputModule/PATH.for
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ C=======================================================================
CHARACTER*6 ERRKEY
CHARACTER*12 NAMEF
CHARACTER*102 DSSATP
CHARACTER*80 LINE,PATHC
CHARACTER*255 LINE,PATHC

INTEGER LUNPR,ERRNUM,PATHL,I,K,PFLAG
LOGICAL FEXIST
Expand All @@ -55,7 +55,7 @@ C=======================================================================
IF (.NOT. FEXIST .OR. ERRNUM .NE. 0) RETURN

DO I = 1, 500
READ (LUNPR,'(A80)',IOSTAT=ERRNUM) LINE
READ (LUNPR,'(A255)',IOSTAT=ERRNUM) LINE
IF (LINE(1:3) .EQ. PROCOD) THEN
! PATHC = LINE(5:6) // LINE(8:80)
call get_next_string(line,4,pathc)
Expand All @@ -75,8 +75,8 @@ C-SUN PATHC = LINE(8:80)
PATHL = PATHL - 1
ENDIF
NAMEF = PATHC (PATHL+1:PATHL+13)
IF (PATHL .LT. 80) THEN
DO K = (PATHL+1),80
IF (PATHL .LT. 255) THEN
DO K = (PATHL+1),255
IF (PATHC(K:K) .NE. BLANK) THEN
PATHC(K:K) = BLANK
ENDIF
Expand Down Expand Up @@ -132,7 +132,7 @@ C=======================================================================

! CHARACTER*12 DSSATF
CHARACTER*102 DSSATP
CHARACTER*120 INPUTX
CHARACTER*255 INPUTX
CHARACTER(len=255) :: DSSAT_HOME

INTEGER I
Expand Down Expand Up @@ -206,10 +206,10 @@ C=======================================================================
CHARACTER*3 PROCOD
CHARACTER*6 ERRKEY
CHARACTER*8 MODEL, CRMODEL
CHARACTER*78 MSG(4)
CHARACTER*80 LINE
CHARACTER*255 MSG(4)
CHARACTER*255 LINE
CHARACTER*102 DSSATP
! CHARACTER*120 PATHX
! CHARACTER*255 PATHX

INTEGER EXE_POS,LUNPR,LINPR,ERRNUM,ISECT,I,J !, IPX
INTEGER ValidModel, LENSTRING
Expand Down
6 changes: 3 additions & 3 deletions InputModule/SECLI.for
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ C=======================================================================
CHARACTER*12 FILEW,WTHTEM,NAMEF
CHARACTER*15 WTMANT,WGMANT
CHARACTER*102 DSSATP
CHARACTER*80 PATHWT
CHARACTER*92 FILEWW,FILEXX
CHARACTER*255 PATHWT
CHARACTER*255 FILEWW,FILEXX

INTEGER MENU,NLOOP,PATHL,YEAR,RSEED1,YR
LOGICAL FEXIST
Expand Down Expand Up @@ -150,7 +150,7 @@ C
WTHTEM = FILEW
ELSE IF (MENU .EQ. 4) THEN
IF (RNMODE .EQ. 'I') WRITE (*,800) PATHWT
READ (5,'(A80)') PATHWT
READ (5,'(A255)') PATHWT
PATHL = INDEX (PATHWT,BLANK)
IF (PATHL .GT. 1) THEN
IF (PATHWT((PATHL-1):(PATHL-1)) .NE. SLASH) THEN
Expand Down
6 changes: 3 additions & 3 deletions InputModule/SECROP.for
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ C=======================================================================
CHARACTER*6 ERRKEY
CHARACTER*16 CROPD
CHARACTER*12 FILEC,FILEE,FILEG
CHARACTER*80 PATHCR
CHARACTER*255 PATHCR

INTEGER MENU,NLOOP

Expand Down Expand Up @@ -127,7 +127,7 @@ C=======================================================================
CHARACTER*6 ERRKEY
CHARACTER*16 CROPD
CHARACTER*12 FILEC,CRPTEM,FILEE,FILEG
CHARACTER*80 PATHCR
CHARACTER*255 PATHCR
CHARACTER*92 FILECC

INTEGER I,NLOOP,PATHL
Expand Down Expand Up @@ -264,7 +264,7 @@ C=======================================================================

CHARACTER*1 LINE(80),RNMODE,BLANK
CHARACTER*12 FILEC,CROPFL
CHARACTER*80 PATHCR
CHARACTER*255 PATHCR
CHARACTER*92 FILECC

INTEGER I,PATHL
Expand Down
6 changes: 3 additions & 3 deletions InputModule/SENS.for
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ C=======================================================================
CHARACTER*25 HARMAN,NIMANT,REMANT
CHARACTER*30 IRMANT
CHARACTER*40 PSMANT
CHARACTER*92 FILEX_P
CHARACTER*255 FILEX_P
CHARACTER*1000 ATLINE

INTEGER MENU,FROP,NSENS,NLOOP
Expand Down Expand Up @@ -457,8 +457,8 @@ C=======================================================================
CHARACTER*1 BLANK,IIRRI,IFERI,IHARI,IRESI,ISWTIL,ISWCHE
CHARACTER*6 ERRKEY
CHARACTER*12 FILEW
CHARACTER*80 PATHWT,LINE
CHARACTER*92 FILEWW
CHARACTER*255 PATHWT,LINE
CHARACTER*255 FILEWW

INTEGER YRSIM,YRPLT,YRDIF,IPLT,ISIM,YR,YEAR,NIRR,NARES,NFERT
INTEGER FDAY(NAPPL),IDLAPL(NAPPL),RESDAY(NAPPL),I,IDATE
Expand Down
4 changes: 2 additions & 2 deletions InputModule/SESIM.for
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ C=======================================================================
CHARACTER*15 NFMANT,WTMANT,PHMANT,INMANT
CHARACTER*16 ETMANT,OMMANT
CHARACTER*17 HYMANT
CHARACTER*80 PATHWT
CHARACTER*255 PATHWT

INTEGER MENU,NLOOP,YEAR,NSWITCH

Expand Down Expand Up @@ -407,7 +407,7 @@ C=======================================================================
CHARACTER*1 RNMODE,MEWTH
CHARACTER*6 ERRKEY
CHARACTER*15 WTMANT
CHARACTER*80 PATHWT
CHARACTER*255 PATHWT

INTEGER NLOOP,MENU

Expand Down
4 changes: 2 additions & 2 deletions InputModule/SESOIL.for
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ C=======================================================================
CHARACTER*6 ERRKEY
CHARACTER*10 PEDON,SLNO
CHARACTER*12 FILES,FILEX
CHARACTER*80 PATHSL
CHARACTER*255 PATHSL
CHARACTER*92 FILESS,FILEX_P

INTEGER MENU,NSENS,NLAYR,NLOOP,LNIC,LNSA,YRIC,PATHL,I !,YRSIM
Expand Down Expand Up @@ -130,7 +130,7 @@ C
ENDIF
ELSE IF (MENU .EQ. 3) THEN
IF (INDEX('IE',RNMODE) .GT. 0) WRITE (*,800) PATHSL
READ (5,'(A80)') PATHSL
READ (5,'(A255)') PATHSL
PATHL = INDEX (PATHSL,BLANK)
IF (PATHL .LE. 1) THEN
FILESS = FILES
Expand Down
4 changes: 2 additions & 2 deletions InputModule/SETIME.for
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ C=======================================================================
CHARACTER*6 ERRKEY
CHARACTER*12 FILEW,WTHTEM
CHARACTER*15 INMANT
CHARACTER*80 PATHWT
CHARACTER*92 FILEWW
CHARACTER*255 PATHWT
CHARACTER*255 FILEWW

INTEGER NLOOP,MENU,YEAR,ISIM,ENDSIM,NYRS,YR,IDUMM,PATHL
INTEGER DSSIM,DESIM,JULIAN,YRSIM,IPYRS,YRPLT,ESIM,EPYRS
Expand Down
4 changes: 2 additions & 2 deletions InputModule/SEVAR.for
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ C=======================================================================
CHARACTER*8 MODEL
CHARACTER*12 FILEE,FILEG
CHARACTER*16 VRNAME,ECONAM
CHARACTER*80 PATHGE,PATHEC
CHARACTER*255 PATHGE,PATHEC
CHARACTER*92 FILEGG
CHARACTER*1000 ATLINE

Expand Down Expand Up @@ -226,7 +226,7 @@ C=======================================================================

CHARACTER*1 LINE(80),RNMODE,BLANK
CHARACTER*12 FILEG,GENTEM
CHARACTER*80 PATHGE
CHARACTER*255 PATHGE
CHARACTER*92 FILEGG

INTEGER I,PATHL,CUL
Expand Down
Loading

0 comments on commit 0f8a496

Please sign in to comment.