Changeset 30610 for trunk/Ohana/src/opihi/cmd.data/reindex.c
- Timestamp:
- Feb 13, 2011, 11:20:31 AM (15 years ago)
- File:
-
- 1 edited
-
trunk/Ohana/src/opihi/cmd.data/reindex.c (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Ohana/src/opihi/cmd.data/reindex.c
r29540 r30610 5 5 int reindex (int argc, char **argv) { 6 6 7 int i, Npts, Nmax , valid;7 int i, Npts, Nmax; 8 8 Vector *ivec, *ovec, *xvec; 9 9 … … 11 11 Npts = 0; 12 12 13 valid = TRUE; 14 valid &= (argc >= 6); 15 valid &= !strcmp(argv[2], "="); 16 valid &= !strcmp(argv[4], "using"); 17 if (!valid) { 18 gprint (GP_ERR, "USAGE: reindex (out) = (in) using (index)\n"); 19 gprint (GP_ERR, " creates a new vectors (out) from (in) based on sequence in (index)\n"); 20 return (FALSE); 21 } 13 if (argc != 6) goto usage; 14 if (strcmp(argv[2], "=")) goto usage; 15 if (strcmp(argv[4], "using")) goto usage; 22 16 23 17 if ((ovec = SelectVector (argv[1], ANYVECTOR, TRUE)) == NULL) goto error; … … 63 57 DeleteVector (ovec); 64 58 return (FALSE); 59 60 usage: 61 gprint (GP_ERR, "USAGE: reindex (out) = (in) using (index)\n"); 62 gprint (GP_ERR, " creates a new vectors (out) from (in) based on sequence in (index)\n"); 63 return (FALSE); 65 64 } 66 65
Note:
See TracChangeset
for help on using the changeset viewer.
