From:	CSBVAX::MRGATE!info-vax-request@kl.sri.com@SMTP 15-FEB-1988 04:58
To:	ARISIA::EVERHART
Subj:	Some changes to SWING


Received: from ucbvax.Berkeley.EDU by KL.SRI.COM with TCP; Wed 10 Feb 88 04:14:05-PST
Received: by ucbvax.Berkeley.EDU (5.58/1.26)
	id AA22984; Wed, 10 Feb 88 04:04:48 PST
Received: from USENET by ucbvax.Berkeley.EDU with netnews
	for info-vax@kl.sri.com (info-vax@kl.sri.com)
	(contact usenet@ucbvax.Berkeley.EDU if you have questions)
Date: 8 Feb 88 11:58:43 GMT
From: mcvax!cernvax!ethz!fede@uunet.uu.net  (F. Bonzanigo)
Organization: ETH Zuerich, Switzerland
Subject: Some changes to SWING
Message-Id: <294@bernina.UUCP>
Sender: info-vax-request@kl.sri.com
To: info-vax@kl.sri.com

Dear Swingers,

One of the changes to SWING posted by Ernie Perkins last August fails if the 
root directory is not on the top level, but is itself a subdirectory. In that 
case one or more spurious points appear in the name of the SWING.SAV file 
(this name is formed by appending "SWING.SAV" to the root directory name. In 
this way one can have various such files for different values of the /START 
qualifier). The name is therefore not a valid file name anymore and one 
obtains the ominous message "Unable to record directory structure". One 
possible correction is to add some code which changes points into underscores.
Following is a portion of the code: the lines I changed are marked with a
"!FBo". These changes have to be introduced in the subroutine LOAD_NODES
which is in the file 3.FOR.
I cannot give an output from DIFFERENCES because I have some other 
corrections and therefore the line numbers will probably not match with yours.

................................................................................
C Stolen from a version posted by Michael Bednarek ....
! Create a file name for the save file 
! The rationale behind this is that I don't want to write the 
! SWING.SAV file into other users' directories.
! If the logical name SWING_SAVE exists,

      If (LIB$SYS_TRNLOG('SWING_SAVE',lTR,TR,,,%VAL(0)).eq.1) then
main(1:len_main+10)='SWING_SAVE:'//main(2:len_main-1)//'_'
len_main = len_main+10
do ii = 1, len_main!FBo
  if (main(ii:ii) .eq. '.')   main(ii:ii) = '_'!FBo
end do!FBo
      End If

      ii = 0
      if ( .not. update .and. lib$find_file( main(1:len_main)//
     .     'swing.sav', input, ii ) ) then

         open( unit=1, 
     .         readonly,
     .         name=main(1:len_main)//'swing.sav', 
     .         status='old',
................................................................................

I would also recommend to make the character variable "main*50" in SWING.CMN
a little longer, e.g. to "main*100".


Federico Bonzanigo
  Institut fuer Elektronik
  Swiss Federal Institute of Technology (ETH)
  CH-8092 Zurich, Switzerland
EAN:         bonzanigo@nimbus.ethz.ch
EARN/BITNET: BONZANIGO@CZHETH5A
EUNET/UUCP:  ...!mcvax!cernvax!ethz!fede
Phone:   +41 (1) 256-5134      (+ = whatever you have to dial
Telefax: +41 (1) 251-2172       to call outside your country)
Telex:   817 379 ehhg ch
