]> git.uio.no Git - u/mrichter/AliRoot.git/blob - GEANT321/gkine/gskinu.F
This commit was generated by cvs2svn to compensate for changes in r2,
[u/mrichter/AliRoot.git] / GEANT321 / gkine / gskinu.F
1 *
2 * $Id$
3 *
4 * $Log$
5 * Revision 1.1.1.1  1995/10/24 10:21:19  cernlib
6 * Geant
7 *
8 *
9 #include "geant321/pilot.h"
10 *CMZ :  3.21/02 29/03/94  15.41.21  by  S.Giani
11 *-- Author :
12       SUBROUTINE GSKINU (ITRA,NWBUF,UBUF,IADR)
13 C.
14 C.    ******************************************************************
15 C.    *                                                                *
16 C     *       Stores User's informations in JKINE  user bank,          *
17 C     *       for track ITRA. (ITRA must be an already existing track) *
18 C     *       IADR is the stating location within the bank.            *
19 C     *                                                                *
20 C     *       on output IADR is the new starting location              *
21 C.    *                                                                *
22 C.    *    ==>Called by : <USER>                                       *
23 C.    *       Author     M.Maire                                       *
24 C.    *                                                                *
25 C.    ******************************************************************
26 C.
27 #include "geant321/gcbank.inc"
28 #include "geant321/gcunit.inc"
29 #include "geant321/gcflag.inc"
30 *
31       DIMENSION UBUF(1)
32 *
33       IF ((JKINE.GT.0).AND.(LQ(JKINE-ITRA).GT.0)) THEN
34 *
35          JK = LQ(JKINE-ITRA)
36          NDATA = IADR + NWBUF
37          IF (LQ(JK-1).EQ.0) THEN
38             CALL MZBOOK (IXDIV,JKU,JK,-1,'KINU',0,0,NDATA,3,0)
39             IQ(JKU-5) = ITRA
40          ELSE
41             JKU = LQ(JK-1)
42             NFREE = IQ(JKU-1) - NDATA
43             IF (NFREE.LT.0) CALL MZPUSH (IXDIV,JKU,0,-NFREE,'I')
44          ENDIF
45 *
46          DO 10 I=1,NWBUF
47             Q(JKU+IADR+I) = UBUF(I)
48    10    CONTINUE
49 *
50          IADR = IADR + NWBUF
51       ELSE
52 *
53          IADR = 0
54          WRITE(CHMAIL,1000) IEVENT,ITRA
55          CALL GMAIL(0,0)
56       ENDIF
57 *
58  1000 FORMAT(' **** GSKINU: No JKINE bank in memory for ievent:',I7,
59      &       '   or track:',I4,'does not exist')
60 *
61       END