Skip to content

Commit

Permalink
memory_utils: fix close_equal()
Browse files Browse the repository at this point in the history
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
  • Loading branch information
Christian Brauner committed Feb 26, 2021
1 parent bf90d19 commit bc70d14
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lxc/memory_utils.h
Expand Up @@ -101,7 +101,7 @@ static inline void *memdup(const void *data, size_t len)
({ \
if (a >= 0 && a != b) \
close(a); \
if (close >= 0) \
if (b >= 0) \
close(b); \
a = b = -EBADF; \
})
Expand Down

0 comments on commit bc70d14

Please sign in to comment.