mirror of
https://github.com/systemd/systemd.git
synced 2025-03-31 14:50:15 +03:00
hwdb: drop useless line freeing
getline() takes care of extending the buffer as needed, so no point in constantly freeing it before every call.
This commit is contained in:
parent
a8e49f5913
commit
d876eea1c4
@ -101,11 +101,6 @@ static int lookup_vid_pid(const char *database,
|
||||
for (;;) {
|
||||
size_t n;
|
||||
|
||||
if (line) {
|
||||
free(line);
|
||||
line = NULL;
|
||||
}
|
||||
|
||||
if (getline(&line, &n, f) < 0)
|
||||
break;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user