[xcrysden] xcrysden-1.5.60 not opening .struct files

Martin Kroeker martin at ruby.chemie.uni-freiburg.de
Wed Jan 28 13:17:21 CET 2015


> On Wed, 2015-01-28 at 12:03 +0100, Martin Kroeker wrote:
> > > Error in startup script: error renaming "Si216}.xcr": no such file or directory
> > The "proc FileHead" in Tcl/auxil.tcl appears to return a brace that was not in the
> > original filename. At first glance it is not clear to me why that
> > procedure is not simply written as 
> > 
> > proc FileHead file {
> >     set filehead [file rootname $file]
> >     regsub -all { } $filehead \. filehead
> > 
> >     return $filehead
> > }
> 
> It should be simply written as:
> 
> proc FileHead file {
>       return [file rootname $file]
> }
> 

Thanks, I was unsure if the replacement of blanks in the filename by
dots was actually used anywhere so I left it in.

> the weird behaviour observed by Victoria. This proc run w/o problems for
> two decades without any such report. I believe the problem lies
> elsewhere. Check if the ./bin/str2xcr binary is functional, i.e., if you
> have a given structu file, say file.struct, then run as:

I'd say that is unlikely to be the root cause of the problem, as "filehead" 
is determined before calling str2xcr. 
Could it be a double dot in the original filename, something like 
Si216..struct  ? I could imagine that the "tcl list mangling" in the
original FileHead proc might fall over when the list created by "split"
contains empty elements "{}".
Hmmm... seeing that the result of "proc FileHead" is not used much anywhere 
else, would it be conceivable that this part of wnOpen.tcl has been happily 
creating (temporary) xcr files with an extraneous brace in them for decades, and
only now str2xcr refuses to create them (or the underlying file system /
operating system / shell does not allow a stray closing brace in filenames) ??

-- 
Dr. Martin Kroeker            martin at ruby.chemie.uni-freiburg.de
c/o Prof.Dr. Caroline Roehr
Institut fuer Anorganische und Analytische Chemie der Universitaet Freiburg



More information about the XCrySDen mailing list