Quoting Tycho Andersen ([email protected]): > We're leaking the FILE* here while closing the underlying fd; let's just > close the file and thus close both. > > Reported-by: Coverity > Signed-off-by: Tycho Andersen <[email protected]>
Interesting. yeah I guess the _IO_FILE has a bunch of extra cruft to drop. I wouldn't have thought of that. Acked-by: Serge E. Hallyn <[email protected]> > --- > src/lxc/criu.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/src/lxc/criu.c b/src/lxc/criu.c > index 667f5d9..adcc626 100644 > --- a/src/lxc/criu.c > +++ b/src/lxc/criu.c > @@ -279,11 +279,11 @@ static bool criu_version_ok() > goto version_error; > > version_match: > - close(pipes[0]); > + fclose(f); > return true; > > version_error: > - close(pipes[0]); > + fclose(f); > ERROR("must have criu " CRIU_VERSION " or greater to > checkpoint/restore\n"); > return false; > } > -- > 2.1.4 > > _______________________________________________ > lxc-devel mailing list > [email protected] > http://lists.linuxcontainers.org/listinfo/lxc-devel _______________________________________________ lxc-devel mailing list [email protected] http://lists.linuxcontainers.org/listinfo/lxc-devel
