diff options
Diffstat (limited to 'drivers/dma-buf/udmabuf.c')
-rw-r--r-- | drivers/dma-buf/udmabuf.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/dma-buf/udmabuf.c b/drivers/dma-buf/udmabuf.c index 8e24204526cc..2e8502250afe 100644 --- a/drivers/dma-buf/udmabuf.c +++ b/drivers/dma-buf/udmabuf.c @@ -194,7 +194,8 @@ err_put_pages: while (pgbuf > 0) put_page(ubuf->pages[--pgbuf]); err_free_ubuf: - fput(memfd); + if (memfd) + fput(memfd); kfree(ubuf->pages); kfree(ubuf); return ret; |