Commit 42ccfc7e authored by Christoph Mallon's avatar Christoph Mallon
Browse files

irdump: Use strstart().

parent d6b21ab5
......@@ -210,14 +210,7 @@ const char *ir_get_dump_filter(void)
/** Returns true if dump file filter is not set, or if it is a prefix of name. */
static int ir_should_dump(const char *name)
{
if (!dump_filter)
return 1;
for (char const *n = name, *f = dump_filter; *f != '\0'; ++n, ++f) {
if (*n != *f)
return 0;
}
return 1;
return !dump_filter || strstart(name, dump_filter);
}
/* -------------- some extended helper functions ----------------- */
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment