mirror of
https://github.com/netsurf-browser/netsurf
synced 2024-12-28 23:09:43 +03:00
Free string vector correctly.
This commit is contained in:
parent
26cecc9f95
commit
0c44eb081e
@ -310,6 +310,10 @@ filepath_path_to_strvec(const char *path)
|
||||
/* exported interface documented in filepath.h */
|
||||
void filepath_free_strvec(char **pathv)
|
||||
{
|
||||
free(pathv[0]);
|
||||
int p = 0;
|
||||
|
||||
while (pathv[p] != NULL) {
|
||||
free(pathv[p++]);
|
||||
}
|
||||
free(pathv);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user