2 comments:
File util/amdfwtool/data_parse.c:
Patch Set #54, Line 265: (void *)
this cast is probably unnecessary, since both sides are amd_bios_entry type
/* get line */
/* blank comment */
if (!regexec(&blank_or_comment_expr, oneline, 0, NULL, 0)) {
/* skip comment and blank */
continue;
}
if (regexec(&entries_line_expr, oneline, 3, match, 0) == 0) {
oneline[match[1].rm_eo] = '\0';
oneline[match[2].rm_eo] = '\0';
} else {
/* no match */
continue;
}
this code is identical to lines 340-353 below, so it's probably a good idea to factor that out into a function (foe example is_valid_config_line(...)) that returns a boolean and then either run the different code parts inside the two loops or continue to the next line
To view, visit change 42859. To unsubscribe, or for help writing mail filters, visit settings.