aboutsummaryrefslogtreecommitdiff
path: root/lib/dma.c
diff options
context:
space:
mode:
authorThanos Makatos <thanos.makatos@nutanix.com>2020-07-08 10:35:33 -0400
committerThanos Makatos <thanos.makatos@nutanix.com>2020-07-08 10:35:33 -0400
commit411cbb3cd9658686fc27dba71edc7d33992bd869 (patch)
treec0565ff0904e4827b39292ec621425848dcd3477 /lib/dma.c
parentf7fa79676d6b25b77cc4fd8d54ffbfa2fa96b2bf (diff)
downloadlibvfio-user-411cbb3cd9658686fc27dba71edc7d33992bd869.zip
libvfio-user-411cbb3cd9658686fc27dba71edc7d33992bd869.tar.gz
libvfio-user-411cbb3cd9658686fc27dba71edc7d33992bd869.tar.bz2
fix assertion
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
Diffstat (limited to 'lib/dma.c')
-rw-r--r--lib/dma.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/dma.c b/lib/dma.c
index 56c3d39..c8e389f 100644
--- a/lib/dma.c
+++ b/lib/dma.c
@@ -130,7 +130,7 @@ dma_controller_remove_region(dma_controller_t *dma,
strerror(-err));
return err;
}
- assert(region->refcnt > 0);
+ assert(region->refcnt == 0);
}
_dma_controller_do_remove_region(dma, region);
if (dma->nregions > 1)