diff options
author | Thanos Makatos <thanos.makatos@nutanix.com> | 2020-11-25 08:19:30 -0500 |
---|---|---|
committer | Thanos <tmakatos@gmail.com> | 2020-11-27 09:36:12 +0000 |
commit | 4235d834cfd090c7d33352adda8762679a132347 (patch) | |
tree | b8f96fe58ea2d30262afda3d0fedd04f598b4169 | |
parent | 76fb4e20298c7c41efb20a8a53ae81d2ce716303 (diff) | |
download | libvfio-user-4235d834cfd090c7d33352adda8762679a132347.zip libvfio-user-4235d834cfd090c7d33352adda8762679a132347.tar.gz libvfio-user-4235d834cfd090c7d33352adda8762679a132347.tar.bz2 |
add assert
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
-rw-r--r-- | lib/dma.c | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -212,6 +212,8 @@ dma_controller_add_region(dma_controller_t *dma, dma_memory_region_t *region; int page_size; + assert(dma != NULL); + if (fd == -1) { errno = EINVAL; return -1; |