state: backend_bucket_circular: fix old state reads
When the circular bucket meta magic was not found, it is assumed that
the whole written state is in the old on-storage format. In that case,
the size of the circular bucket meta must not be subtracted from the
read length, or the (complete_len > len) check in the raw backend's
verify function will fail:

    state: Error, invalid data_len 16 in header, have data of len 24

Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
1 parent e667f82 commit a0c26429e472a175ac6b1736c8687a19a76e97a9
@Philipp Zabel Philipp Zabel authored on 18 Jul 2017
Lucas Stach committed on 20 Jul 2017
Showing 1 changed file
View
common/state/backend_bucket_circular.c