Skip to content

Commit

Permalink
coverity: closedir on error path
Browse files Browse the repository at this point in the history
Signed-off-by: Serge Hallyn <serge.hallyn@ubuntu.com>
  • Loading branch information
hallyn committed Oct 7, 2013
1 parent dab75ac commit 9baa57b
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/lxc/lxccontainer.c
Expand Up @@ -2538,6 +2538,10 @@ static int lxcapi_snapshot_list(struct lxc_container *c, struct lxc_snapshot **r
lxcsnap_free(&snaps[i]);
free(snaps);
}
process_lock();
if (closedir(dir))
WARN("failed to close directory");
process_unlock();
return -1;
}

Expand Down

0 comments on commit 9baa57b

Please sign in to comment.