Update missed parameter names

This commit is contained in:
Nick Chambers 2022-06-24 08:20:50 -05:00
parent 86a3ab5eca
commit c49726b8b8
1 changed files with 3 additions and 3 deletions

View File

@ -16,7 +16,7 @@ uint8_t gargoyle_from_rope(struct gargoyle_opt *opt, const char *brand_val) {
if(opt->type & GARGOYLE_TYPE_UINT) {
char *end = NULL;
uint64_t *val = opt->val;
*val = strtoull(brand, &end, 10);
*val = strtoull(brand_val, &end, 10);
if(*end) {
return GARGOYLE_ERR_INVALID_UINT;
@ -24,14 +24,14 @@ uint8_t gargoyle_from_rope(struct gargoyle_opt *opt, const char *brand_val) {
} else if(opt->type & GARGOYLE_TYPE_DBLE) {
char *end = NULL;
double *val = opt->val;
*val = strtod(brand, &end);
*val = strtod(brand_val, &end);
if(*end) {
return GARGOYLE_ERR_INVALID_DBLE;
}
} else if(opt->type & GARGOYLE_TYPE_ROPE) {
char *val = opt->val;
char *end = gargoyle_cpy(val, brand, opt->val_sz - 1);
char *end = gargoyle_cpy(val, brand_val, opt->val_sz - 1);
*end = '\0';
} else {
return GARGOYLE_ERR_UNKNOWN_TYPE;