UBI: fix double free on error path
authorAdrian Hunter <Adrian.Hunter@nokia.com>
Fri, 24 Jul 2009 14:05:00 +0000 (17:05 +0300)
committerArtem Bityutskiy <Artem.Bityutskiy@nokia.com>
Sun, 26 Jul 2009 11:21:53 +0000 (14:21 +0300)
If we fail in 'ubi_eba_init_scan()', we free
'ubi->volumes[i]->eba_tbl' in there, but also later free it
in 'free_internal_volumes()'. Fix this by assigning NULL
to 'ubi->volumes[i]->eba_tbl' after it is freed.

Signed-off-by: Adrian Hunter <adrian.hunter@nokia.com>
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>

No differences found