Add missing fio_mutex_up() on return
authorTomohiro Kusumi <kusumi.tomohiro@gmail.com>
Sat, 16 May 2015 01:10:57 +0000 (10:10 +0900)
committerTomohiro Kusumi <kusumi.tomohiro@gmail.com>
Sat, 16 May 2015 01:52:39 +0000 (10:52 +0900)
Call fio_mutex_up() before returning from this function.

flow.c

diff --git a/flow.c b/flow.c
index f9d868d8e7505c3a0cdb3adc8a7b2bb806526984..e0ac13521f453ed32f2e1ce2fbcdaeb93e70adcc 100644 (file)
--- a/flow.c
+++ b/flow.c
@@ -59,6 +59,7 @@ static struct fio_flow *flow_get(unsigned int id)
                flow = smalloc(sizeof(*flow));
                if (!flow) {
                        log_err("fio: smalloc pool exhausted\n");
+                       fio_mutex_up(flow_lock);
                        return NULL;
                }
                flow->refs = 0;