Browse Source

inpcom.c, cleanup, use strchr()

pre-master-46
h_vogt 9 years ago
committed by rlar
parent
commit
cf9dbff890
  1. 7
      src/frontend/inpcom.c

7
src/frontend/inpcom.c

@ -5431,14 +5431,13 @@ inp_temper_compat(struct line *card)
continue; continue;
} }
/* exclude some elements */ /* exclude some elements */
if ((*curr_line == '*') || (*curr_line == 'v') || (*curr_line == 'b') || (*curr_line == 'i') ||
(*curr_line == 'e') || (*curr_line == 'g') || (*curr_line == 'f') || (*curr_line == 'h'))
if (strchr("*vbiegfh", curr_line[0]))
continue; continue;
/* exclude all dot commands except .model */ /* exclude all dot commands except .model */
if ((*curr_line == '.') && (!prefix(".model", curr_line)))
if (curr_line[0] == '.' && !prefix(".model", curr_line))
continue; continue;
/* exclude lines not containing 'temper' */ /* exclude lines not containing 'temper' */
if (strstr(curr_line, "temper") == NULL)
if (!strstr(curr_line, "temper"))
continue; continue;
/* now start processing of the remaining lines containing 'temper' */ /* now start processing of the remaining lines containing 'temper' */
/* remove white spaces of everything inside {}*/ /* remove white spaces of everything inside {}*/

Loading…
Cancel
Save