tree-wide: use coccinelle to patch a lot of code to use mfree()
This replaces this:
free(p);
p = NULL;
by this:
p = mfree(p);
Change generated using coccinelle. Semantic patch is added to the
sources.
This commit is contained in:
@@ -145,8 +145,7 @@ void release_lock_file(LockFile *f) {
|
||||
if ((f->operation & ~LOCK_NB) == LOCK_EX)
|
||||
unlink_noerrno(f->path);
|
||||
|
||||
free(f->path);
|
||||
f->path = NULL;
|
||||
f->path = mfree(f->path);
|
||||
}
|
||||
|
||||
f->fd = safe_close(f->fd);
|
||||
|
||||
Reference in New Issue
Block a user