Commit c8e2876f authored by Al Viro's avatar Al Viro Committed by Richard Weinberger

um: finally kill ->init_str leaks

now we can do that...
Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
Signed-off-by: default avatarRichard Weinberger <richard@nod.at>
parent 04292b2c
......@@ -509,8 +509,10 @@ int setup_one_line(struct line *lines, int n, char *init,
*error_out = "Failed to allocate memory";
return -ENOMEM;
}
if (line->valid)
if (line->valid) {
tty_unregister_device(driver, n);
kfree(line->init_str);
}
line->init_str = new;
line->valid = 1;
err = parse_chan_pair(new, line, n, opts, error_out);
......
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