/usr/share/gnudatalanguage/astrolib/textclose.pro is in gdl-astrolib 2018.02.16+dfsg-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 | pro textclose,textout=textout
;+
; NAME:
; TEXTCLOSE
;
; PURPOSE:
; Close a text outpu file previously opened with TEXTOPEN
; EXPLANATION:
; procedure to close file for text output as specifed
; by the (non-standard) system variable !TEXTOUT.
;
; CALLING SEQUENCE:
; textclose, [ TEXTOUT = ]
;
; KEYWORDS:
; textout - Indicates output device that was used by
; TEXTOPEN
;
; SIDE EFFECTS:
; if !textout is not equal to 5 and the textunit is
; opened. Then unit !textunit is closed and released
;
; HISTORY:
; D. Lindler Dec. 1986 (Replaces PRTOPEN)
; Test if TEXTOUT is a scalar string W. Landsman August 1993
; Can't close unit -1 (Standard Output) I. Freedman April 1994
; Converted to IDL V5.0 W. Landsman September 1997
;-
;-----------------------------------------------------------
; CLOSE PROPER UNIT
;
if N_elements( textout ) EQ 0 then textout = !textout ;use default
ptype = size( textout ) ;Test if TEXTOUT is a scalar string
if ptype[1] EQ 7 then text_out = 6 else text_out = textout
if ( text_out NE 5 ) then begin
if !textunit ne 0 AND !textunit ne -1 then begin
free_lun, !TEXTUNIT
!textunit = 0
end
end
return
end
|