Several of the MINC shell scripts generate temporary files/dirs that are solely based on pid. This can lead to name clashes with past runs on the same host, if these tempdirs/files were not cleaned up (which can happen under various circumstances - qdel being one of them). This in turn would cause these tools to crash when they shouldn't have. Specifically, these are affected:
mincdiff
mincedit
mincheader
In addition, some of these create their temporary dir even when it is not needed or used (mostly to decompress - outdated - externally compressed .mnc.gz files), which creates a bit of unnecessary I/O.
Suggest to improve the tempdir/file handling in these tools to be more robust. @gdevenyi suggested to use "mktemp -d".
Several of the MINC shell scripts generate temporary files/dirs that are solely based on pid. This can lead to name clashes with past runs on the same host, if these tempdirs/files were not cleaned up (which can happen under various circumstances - qdel being one of them). This in turn would cause these tools to crash when they shouldn't have. Specifically, these are affected:
mincdiff mincedit mincheader
In addition, some of these create their temporary dir even when it is not needed or used (mostly to decompress - outdated - externally compressed .mnc.gz files), which creates a bit of unnecessary I/O.
Suggest to improve the tempdir/file handling in these tools to be more robust. @gdevenyi suggested to use "mktemp -d".