Changeset 33870 for branches/eam_branches/ipp-20120405/Ohana
- Timestamp:
- May 16, 2012, 4:16:48 PM (14 years ago)
- Location:
- branches/eam_branches/ipp-20120405/Ohana/src/opihi/dvo
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/eam_branches/ipp-20120405/Ohana/src/opihi/dvo/dvo_host_utils.c
r33662 r33870 4 4 # define PARALLEL_MANUAL 0 5 5 # define PARALLEL_SERIAL 0 6 # define MAX_PATH_LENGTH 10246 # define DVO_MAX_PATH 1024 7 7 8 8 int HostTableLaunchJobs (HostTable *table, char *basecmd, char *options) { … … 17 17 18 18 // ensure that the paths are absolute path names 19 char *tmppath = abspath (table->hosts[i].pathname, MAX_PATH_LENGTH);19 char *tmppath = abspath (table->hosts[i].pathname, DVO_MAX_PATH); 20 20 free (table->hosts[i].pathname); 21 21 table->hosts[i].pathname = tmppath; … … 23 23 // need to save the results filename with the uniquer 24 24 // XXX a bit of a waste (but only 1024 * 60 bytes or so 25 ALLOCATE (table->hosts[i].results, char, MAX_PATH_LENGTH);26 snprintf (table->hosts[i].results, MAX_PATH_LENGTH, "%s/dvo.results.%s.fits", table->hosts[i].pathname, uniquer);25 ALLOCATE (table->hosts[i].results, char, DVO_MAX_PATH); 26 snprintf (table->hosts[i].results, DVO_MAX_PATH, "%s/dvo.results.%s.fits", table->hosts[i].pathname, uniquer); 27 27 28 char commandBase[ MAX_PATH_LENGTH];29 snprintf (commandBase, MAX_PATH_LENGTH, "dvo.command.%s.txt", uniquer);30 char *commandFile = abspath(commandBase, MAX_PATH_LENGTH);28 char commandBase[DVO_MAX_PATH]; 29 snprintf (commandBase, DVO_MAX_PATH, "dvo.command.%s.txt", uniquer); 30 char *commandFile = abspath(commandBase, DVO_MAX_PATH); 31 31 32 32 FILE *f = fopen (commandFile, "w"); … … 86 86 } 87 87 88 char *CATDIR = abspath (tmppath, MAX_PATH_LENGTH);88 char *CATDIR = abspath (tmppath, DVO_MAX_PATH); 89 89 if (!CATDIR) { 90 90 gprint (GP_ERR, "failed to make an absolute path from %s (too long)\n", tmppath); -
branches/eam_branches/ipp-20120405/Ohana/src/opihi/dvo/hosts.c
r33662 r33870 1 1 # include "dvoshell.h" 2 2 # include <glob.h> 3 # define MAX_PATH_LENGTH 10243 # define DVO_MAX_PATH 1024 4 4 5 5 // functions to manage the remote hosts … … 59 59 for (i = 0; i < table->Nhosts; i++) { 60 60 pglob.gl_offs = 0; 61 char name[ MAX_PATH_LENGTH];62 snprintf (name, MAX_PATH_LENGTH, "%s/dvo.results.%05d.*.fits", table->hosts[i].pathname, PID);61 char name[DVO_MAX_PATH]; 62 snprintf (name, DVO_MAX_PATH, "%s/dvo.results.%05d.*.fits", table->hosts[i].pathname, PID); 63 63 if (VERBOSE) gprint (GP_ERR, "checking %s\n", name); 64 64 glob (name, 0, NULL, &pglob); -
branches/eam_branches/ipp-20120405/Ohana/src/opihi/dvo/remote.c
r33662 r33870 1 1 # include "dvoshell.h" 2 2 # include <glob.h> 3 # define MAX_PATH_LENGTH 10243 # define DVO_MAX_PATH 1024 4 4 5 5 // functions to manage the remote hosts
Note:
See TracChangeset
for help on using the changeset viewer.
