ECCE @ EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
luerrm.f
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file luerrm.f
1 
2 C*********************************************************************
3 
4  SUBROUTINE luerrm(MERR,CHMESS)
5 
6 C...Purpose: to inform user of errors in program execution.
7  common/lujets/n,k(9000,5),p(9000,5),v(9000,5)
8  SAVE /lujets/
9  common/ludat1/mstu(200),paru(200),mstj(200),parj(200)
10  SAVE /ludat1/
11  CHARACTER chmess*(*)
12 
13 C...Write first few warnings, then be silent.
14  IF(merr.LE.10) THEN
15  mstu(27)=mstu(27)+1
16  mstu(28)=merr
17  IF(mstu(25).EQ.1.AND.mstu(27).LE.mstu(26)) WRITE(mstu(11),1000)
18  & merr,mstu(31),chmess
19 
20 C...Write first few errors, then be silent or stop program.
21  ELSEIF(merr.LE.20) THEN
22  mstu(23)=mstu(23)+1
23  mstu(24)=merr-10
24  IF(mstu(21).GE.1.AND.mstu(23).LE.mstu(22)) WRITE(mstu(11),1100)
25  & merr-10,mstu(31),chmess
26  IF(mstu(21).GE.2.AND.mstu(23).GT.mstu(22)) THEN
27  WRITE(mstu(11),1100) merr-10,mstu(31),chmess
28  WRITE(mstu(11),1200)
29  IF(merr.NE.17) CALL lulist(2)
30  stop
31  ENDIF
32 
33 C...Stop program in case of irreparable error.
34  ELSE
35  WRITE(mstu(11),1300) merr-20,mstu(31),chmess
36  stop
37  ENDIF
38 
39 C...Formats for output.
40  1000 FORMAT(/5x,'Advisory warning type',i2,' given after',i6,
41  &' LUEXEC calls:'/5x,a)
42  1100 FORMAT(/5x,'Error type',i2,' has occured after',i6,
43  &' LUEXEC calls:'/5x,a)
44  1200 FORMAT(5x,'Execution will be stopped after listing of last ',
45  &'event!')
46  1300 FORMAT(/5x,'Fatal error type',i2,' has occured after',i6,
47  &' LUEXEC calls:'/5x,a/5x,'Execution will now be stopped!')
48 
49  RETURN
50  END