| 1 |
C Copyright(C) 1999-2020 National Technology & Engineering Solutions |
| 2 |
C of Sandia, LLC (NTESS). Under the terms of Contract DE-NA0003525 with |
| 3 |
C NTESS, the U.S. Government retains certain rights in this software. |
| 4 |
C |
| 5 |
C See packages/seacas/LICENSE for details |
| 6 |
|
| 7 |
C======================================================================= |
| 8 |
LOGICAL FUNCTION MEMEXT(IB,MEMRY,INCL) |
| 9 |
INTEGER IB |
| 10 |
INTEGER MEMRY(*) |
| 11 |
INTEGER DELTA |
| 12 |
INTEGER MEMALL |
| 13 |
LOGICAL MEMFRE |
| 14 |
INTEGER LA |
| 15 |
INTEGER IBT |
| 16 |
C ... Guess by GDS -- DELTA not defined, set to 0 since that is |
| 17 |
C what it would be on VMS if undefined. |
| 18 |
DELTA = 0 |
| 19 |
LA = MEMRY(IB-2) - IB |
| 20 |
IBT = IB |
| 21 |
INCL = LA + DELTA |
| 22 |
IB = MEMALL(INCL,MEMRY) |
| 23 |
DO 2780 I = 1,LA |
| 24 |
MEMRY(IB+I-1) = MEMRY(IBT+I-1) |
| 25 |
2780 CONTINUE |
| 26 |
IF (.NOT.MEMFRE(IBT,MEMRY)) THEN |
| 27 |
WRITE (6,*) 'Error deallocating old segment.' |
| 28 |
MEMEXT = .FALSE. |
| 29 |
RETURN |
| 30 |
|
| 31 |
END IF |
| 32 |
|
| 33 |
MEMEXT = .TRUE. |
| 34 |
RETURN |
| 35 |
|
| 36 |
END |