Explain why we use raw_free with getdelim result.

This commit is contained in:
Nick Mathewson
2018-07-10 20:16:37 -04:00
parent c4dd38e625
commit 391ef5e42c
+3 -1
View File
@@ -2682,8 +2682,10 @@ dirserv_read_measured_bandwidths(const char *from_file,
rv = 0;
err:
if (line)
if (line) {
// we need to raw_free this buffer because we got it from tor_getdelim()
raw_free(line);
}
if (fp)
fclose(fp);
return rv;