1
0
mirror of https://git.proxmox.com/git/mirror_zfs.git synced 2025-05-05 16:32:44 +03:00

libzfs_core: fini: don't check for refcount twice

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: John Kennedy <john.kennedy@delphix.com>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes 
This commit is contained in:
наб 2021-05-20 22:29:33 +02:00 committed by Brian Behlendorf
parent c71a2bb52f
commit a0cb347cea

View File

@ -158,7 +158,6 @@ libzfs_core_fini(void)
(void) pthread_mutex_lock(&g_lock); (void) pthread_mutex_lock(&g_lock);
ASSERT3S(g_refcount, >, 0); ASSERT3S(g_refcount, >, 0);
if (g_refcount > 0)
g_refcount--; g_refcount--;
if (g_refcount == 0 && g_fd != -1) { if (g_refcount == 0 && g_fd != -1) {