Changeset 12905 for trunk/psModules/src/config/pmConfig.c
- Timestamp:
- Apr 18, 2007, 12:20:28 PM (19 years ago)
- File:
-
- 1 edited
-
trunk/psModules/src/config/pmConfig.c (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psModules/src/config/pmConfig.c
r12890 r12905 4 4 * @author EAM (IfA) 5 5 * 6 * @version $Revision: 1.8 6$ $Name: not supported by cvs2svn $7 * @date $Date: 2007-04-18 19:42:37$6 * @version $Revision: 1.87 $ $Name: not supported by cvs2svn $ 7 * @date $Date: 2007-04-18 22:20:28 $ 8 8 * 9 9 * Copyright 2004 Maui High Performance Computing Center, University of Hawaii … … 62 62 psFree(config->arguments); 63 63 psFree(config->database); 64 } 65 66 pmConfig *pmConfigAlloc(int *argc, char **argv) 64 for (int i = 0; i < argc; i++) { 65 psFree (config->argv[i]); 66 } 67 psFree (config->argv); 68 } 69 70 pmConfig *pmConfigAlloc(int argc, char **argv) 67 71 { 68 72 pmConfig *config = psAlloc(sizeof(pmConfig)); … … 80 84 config->arguments = psMetadataAlloc(); 81 85 config->database = NULL; 86 config->defaultRecipe = NULL; 87 82 88 config->argc = argc; 83 config->argv = argv; 84 config->defaultRecipe = NULL; 89 config->argv = (char *)psAlloc (argc*sizeof(char *)); 90 for (int i = 0; i < argc; i++) { 91 config->argv[i] = psStringCopy(argv[i]); 92 } 85 93 86 94 // the file structure is used to carry pmFPAfiles
Note:
See TracChangeset
for help on using the changeset viewer.
