exofs: Fix bio leak in error handling path (sync read)

When failing a read request in the sync path, called from
write_begin, I forgot to free the allocated bio, fix it.

Signed-off-by: Boaz Harrosh <bharrosh@panasas.com>
This commit is contained in:
Boaz Harrosh 2009-06-08 19:28:41 +03:00
Родитель c277331d5f
Коммит b76a3f93d0
1 изменённых файлов: 3 добавлений и 0 удалений

Просмотреть файл

@ -295,6 +295,9 @@ static int read_exec(struct page_collect *pcol, bool is_sync)
err:
if (!is_sync)
_unlock_pcol_pages(pcol, ret, READ);
else /* Pages unlocked by caller in sync mode only free bio */
pcol_free(pcol);
kfree(pcol_copy);
if (or)
osd_end_request(or);