- Timestamp:
- Jul 19, 2019, 5:31:16 PM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/eam_branches/ohana.20190329/src/opihi/cmd.data/spline_commands.c
r40813 r40836 28 28 if (xvec->Nelements != yvec->Nelements) { 29 29 gprint (GP_ERR, "x and y vectors must be the same length\n"); 30 return FALSE; 31 } 32 33 if (xvec->Nelements < 3) { 34 gprint (GP_ERR, "cannot make a spline with fewer than 3 knots\n"); 30 35 return FALSE; 31 36 } … … 132 137 133 138 int N, status; 134 Spline *spline;135 139 136 140 int QUIET = FALSE; … … 145 149 } 146 150 147 spline = FindSpline (argv[1]);151 Spline *spline = FindSpline (argv[1]); 148 152 if (spline == NULL) { 149 153 if (QUIET) return TRUE; … … 159 163 int spline_rename (int argc, char **argv) { 160 164 161 Spline *spline;162 163 165 if (argc != 3) { 164 166 gprint (GP_ERR, "USAGE: spline rename (spline) (newname)\n"); … … 166 168 } 167 169 168 spline = FindSpline (argv[1]);170 Spline *spline = FindSpline (argv[1]); 169 171 if (spline == NULL) { 170 172 gprint (GP_ERR, "spline %s not found\n", argv[1]); 171 173 return FALSE; 174 } 175 176 Spline *newname = FindSpline (argv[2]); 177 if (newname != NULL) { 178 DeleteSpline (newname); 172 179 } 173 180 … … 176 183 return TRUE; 177 184 } 178 179 /*180 int spline_listspline (int argc, char **argv) {181 182 Spline *spline;183 184 if (argc != 2) {185 gprint (GP_ERR, "USAGE: spline listspline (spline)\n");186 return FALSE;187 }188 189 spline = FindSpline (argv[1]);190 if (spline == NULL) {191 gprint (GP_ERR, "spline %s not found\n", argv[1]);192 return FALSE;193 }194 195 ListPages (spline);196 return TRUE;197 }198 */199
Note:
See TracChangeset
for help on using the changeset viewer.
