
                                                                12-Feb-1991 11:42:28	VAX FORTRAN V5.5-98                 Page   1
                                                                15-May-1990 10:19:09	USR3:[UTIL.NASAUTIL.MAILUTIL]NETUAF.FOR;39  

0001    	OPTIONS/EXTEND
0002    	SUBROUTINE	NETUAF( CHK_NAME, NET_NAME, LEN_CHK, LEN_NET )
0003    C
0004    	INTEGER*4	ID_LEN, NODE_LEN, LEN_CHK, LEN_NET
0005    	CHARACTER	REM_ID*32, REM_NODE*32, CHK_NAME*31, NET_NAME*31
0006    	CHARACTER*32	NET_ID, LOC_NAME, NEW_NAME
0007    C
0008    	COMMON /REMOTE/ ID_LEN, REM_ID, NODE_LEN, REM_NODE
0009    C
0010    	CALL GET_REMOTE
0011    C
0012    	LOC_NAME = ' '
0013    C
0014    	IF ((ID_LEN .EQ. 0) .OR. (NODE_LEN .LE. 0)) GOTO 200
0015    C
0016    	OPEN (UNIT=10, FILE='SYS$SYSTEM:NETPROXY.DAT', STATUS='OLD',
0017         &		ACCESS='KEYED',ORGANIZATION='INDEXED',
0018         &		CARRIAGECONTROL='NONE', READONLY, SHARED,
0019         &		KEY=(13:76:CHARACTER), FORM='FORMATTED' )
0020    C
0021    	READ (10, 550, KEYEQ=REM_NODE, KEYID=0, IOSTAT=IERR) NET_ID, NEW_NAME, LOC_NAME
0022    C
0023    	DO WHILE ((IERR .EQ. 0) .AND. 
0024         &		(REM_NODE(1:NODE_LEN) .EQ. NET_ID(1:NODE_LEN)) .AND.
0025         &		(CHK_NAME(1:LEN_CHK) .NE. LOC_NAME(1:LEN_CHK)))
0026    C	
0027    		READ (10, 550, IOSTAT=IERR) NET_ID, NEW_NAME, LOC_NAME
0028    C
0029    	ENDDO
0030    C
0031    	CLOSE(UNIT=10)
0032    C
0033    550	FORMAT(A32,A32,A32)
0034    C
0035    100	IF (CHK_NAME(1:LEN_CHK) .NE. LOC_NAME(1:LEN_CHK)) THEN
0036    		NET_NAME = 'NAME_NOT_FOUND_'//CHK_NAME(1:LEN_CHK)
0037    		LEN_NET = 15 + LEN_CHK
0038    	ELSE
0039    		CALL STR$TRIM(NEW_NAME, NEW_NAME, LEN_NETNAME )
0040    		LEN_NET  = NODE_LEN + 2 + LEN_NETNAME 
0041    		NEW_NAME = NET_ID(1:NODE_LEN)//'::'//NEW_NAME(1:LEN_NETNAME)
0042    		NET_NAME = ' '
0043    		NET_NAME(1:LEN_NET) = NEW_NAME(1:LEN_NET)
0044    	ENDIF
0045    C
0046    	RETURN
0047    C
0048    200	NET_NAME = 'NODE_NOT_FOUND'
0049    	LEN_NET = 14
0050    C
0051    	RETURN
0052    C
0053    	END

NETUAF                                                          12-Feb-1991 11:42:28	VAX FORTRAN V5.5-98                 Page   2
01                                                              15-May-1990 10:19:09	USR3:[UTIL.NASAUTIL.MAILUTIL]NETUAF.FOR;39  

PROGRAM SECTIONS

    Name				 Bytes   Attributes

  0 $CODE                                  400   PIC CON REL LCL   SHR   EXE   RD NOWRT QUAD
  1 $PDATA                                  60   PIC CON REL LCL   SHR NOEXE   RD NOWRT QUAD
  2 $LOCAL                                 244   PIC CON REL LCL NOSHR NOEXE   RD   WRT QUAD
  3 REMOTE                                  72   PIC OVR REL GBL   SHR NOEXE   RD   WRT QUAD

    Total Space Allocated                  776


ENTRY POINTS

    Address  Type  Name          

  0-00000000       NETUAF        


VARIABLES

    Address  Type  Name              Address  Type  Name              Address  Type  Name              Address  Type  Name          

 AP-00000004@ CHAR CHK_NAME        3-00000000  I*4  ID_LEN              **      I*4  IERR           AP-0000000C@ I*4  LEN_CHK       
 AP-00000010@ I*4  LEN_NET         2-00000060  I*4  LEN_NETNAME     2-00000020  CHAR LOC_NAME        2-00000000  CHAR NET_ID        
 AP-00000008@ CHAR NET_NAME        2-00000040  CHAR NEW_NAME        3-00000024  I*4  NODE_LEN        3-00000004  CHAR REM_ID        
  3-00000028  CHAR REM_NODE      


LABELS

    Address   Label       Address   Label       Address   Label   

      **      100       0-00000180  200       1-00000018  550'    


FUNCTIONS AND SUBROUTINES REFERENCED

  Type  Name            Type  Name            Type  Name            Type  Name          

        FOR$CLOSE             FOR$OPEN              GET_REMOTE            STR$TRIM      


OPTIONS QUALIFIERS

  /CHECK=(NOBOUNDS,OVERFLOW,NOUNDERFLOW)
  /EXTEND_SOURCE  /F77  /NOG_FLOATING  /I4

                                                                12-Feb-1991 11:42:28	VAX FORTRAN V5.5-98                 Page   3
                                                                15-May-1990 10:19:09	USR3:[UTIL.NASAUTIL.MAILUTIL]NETUAF.FOR;39  

0002    	SUBROUTINE	GET_REMOTE()
0003    C
0004    	INTEGER*4	SYS$TRNLNM
0005    	INTEGER*2	NAME_LEN, NAME_CODE
0006    	INTEGER*4	NAME_ADDR, RET_ADDR, END_LIST /0/
0007    	INTEGER*4	STATUS_L, LNM_LEN, ID_LEN, NODE_LEN
0008    	CHARACTER	LNM_STRING*72, REM_ID*32, REM_NODE*32
0009    C
0010    	COMMON /REMOTE/ ID_LEN, REM_ID, NODE_LEN, REM_NODE
0011    C
0012    	COMMON /LIST/ NAME_LEN, NAME_CODE, NAME_ADDR, RET_ADDR, END_LIST
0013    C
0014    	LNM$_STRING = 2
0015    C
0016    	NAME_LEN = 32
0017    	NAME_CODE = (LNM$_STRING)
0018    	NAME_ADDR = %LOC(LNM_STRING)
0019    	RET_ADDR = %LOC(LNM_LEN)
0020    C
0021    	REM_ID = ' '
0022    	REM_NODE = ' '
0023    	LNM_STRING = ' '
0024    C
0025    	STATUS_L = SYS$TRNLNM(, 'LNM$JOB', 'SYS$REM_ID',, NAME_LEN )
0026    		IF (.NOT. STATUS_L) CALL LIB$SIGNAL(%VAL(STATUS_L))
0027    C
0028    	ID_LEN = LNM_LEN
0029    	IF (ID_LEN .EQ. 0) GOTO 100
0030    C
0031    	REM_ID(1:ID_LEN) = LNM_STRING(1:ID_LEN)
0032    C
0033    100	LNM_STRING = ' '
0034    C
0035    	STATUS_L = SYS$TRNLNM(, 'LNM$JOB', 'SYS$REM_NODE',, NAME_LEN )
0036    		IF (.NOT. STATUS_L) CALL LIB$SIGNAL(%VAL(STATUS_L))
0037    C
0038    	NODE_LEN = LNM_LEN - 2
0039    	IF (NODE_LEN .LE. 0) RETURN
0040    	REM_NODE(1:NODE_LEN) = LNM_STRING(1:NODE_LEN)
0041    C
0042    	RETURN
0043    	END

GET_REMOTE                                                      12-Feb-1991 11:42:28	VAX FORTRAN V5.5-98                 Page   4
01                                                              15-May-1990 10:19:09	USR3:[UTIL.NASAUTIL.MAILUTIL]NETUAF.FOR;39  

PROGRAM SECTIONS

    Name				 Bytes   Attributes

  0 $CODE                                  152   PIC CON REL LCL   SHR   EXE   RD NOWRT QUAD
  1 $PDATA                                  32   PIC CON REL LCL   SHR NOEXE   RD NOWRT QUAD
  2 $LOCAL                                 172   PIC CON REL LCL NOSHR NOEXE   RD   WRT QUAD
  3 REMOTE                                  72   PIC OVR REL GBL   SHR NOEXE   RD   WRT QUAD
  4 LIST                                    16   PIC OVR REL GBL   SHR NOEXE   RD   WRT QUAD

    Total Space Allocated                  444


ENTRY POINTS

    Address  Type  Name          

  0-00000000       GET_REMOTE    


VARIABLES

    Address  Type  Name              Address  Type  Name              Address  Type  Name              Address  Type  Name          

  4-0000000C  I*4  END_LIST        3-00000000  I*4  ID_LEN              **      I*4  LNM$_STRING     2-00000048  I*4  LNM_LEN       
  2-00000000  CHAR LNM_STRING      4-00000004  I*4  NAME_ADDR       4-00000002  I*2  NAME_CODE       4-00000000  I*2  NAME_LEN      
  3-00000024  I*4  NODE_LEN        3-00000004  CHAR REM_ID          3-00000028  CHAR REM_NODE        4-00000008  I*4  RET_ADDR      
      **      I*4  STATUS_L      


LABELS

    Address   Label   

  0-00000066  100     


FUNCTIONS AND SUBROUTINES REFERENCED

  Type  Name            Type  Name          

        LIB$SIGNAL       I*4  SYS$TRNLNM    


COMMAND QUALIFIERS

  FOR/LIST NETUAF

  /CHECK=(NOBOUNDS,OVERFLOW,NOUNDERFLOW)
  /DEBUG=(NOSYMBOLS,TRACEBACK)
  /DESIGN=(NOCOMMENTS,NOPLACEHOLDERS)
  /SHOW=(NODICTIONARY,NOINCLUDE,MAP,NOPREPROCESSOR,SINGLE)
  /STANDARD=(NOSEMANTIC,NOSOURCE_FORM,NOSYNTAX)
  /WARNINGS=(NODECLARATIONS,GENERAL,NOULTRIX,NOVAXELN)
  /CONTINUATIONS=19  /NOCROSS_REFERENCE  /NOD_LINES  /NOEXTEND_SOURCE
  /F77  /NOG_FLOATING  /I4  /NOMACHINE_CODE  /OPTIMIZE  /NOPARALLEL
  /NOANALYSIS_DATA

GET_REMOTE                                                      12-Feb-1991 11:42:28	VAX FORTRAN V5.5-98                 Page   5
01                                                              15-May-1990 10:19:09	USR3:[UTIL.NASAUTIL.MAILUTIL]NETUAF.FOR;39  

  /NODIAGNOSTICS
  /LIST=USR3:[UTIL.NASAUTIL.MAILUTIL]NETUAF.LIS;1                                                           
  /OBJECT=USR3:[UTIL.NASAUTIL.MAILUTIL]NETUAF.OBJ;3                                                           


COMPILATION STATISTICS

  Run Time:           1.44 seconds
  Elapsed Time:       1.98 seconds
  Page Faults:        707
  Dynamic Memory:     488 pages
