OSDN Git Service

btrfs: tests: return errors from extent map tests
authorDavid Sterba <dsterba@suse.com>
Fri, 15 Mar 2019 17:06:16 +0000 (18:06 +0100)
committerDavid Sterba <dsterba@suse.com>
Mon, 29 Apr 2019 17:02:26 +0000 (19:02 +0200)
commit488f673023be9a0a5d3f2078e294ff3be907efe0
treeb97bc0296968ed35e1dfa77a3985964ce5b3770e
parent7b9586bc2b31b8f62da651cb0ddf926997c93954
btrfs: tests: return errors from extent map tests

The individual testcases for extent maps do not return an error on
allocation failures. This is not a big problem as the allocation don't
fail in general but there are functional tests handled with ASSERTS.
This makes tests dependent on them and it's not reliable.

This patch adds the allocation failure handling and allows for the
conversion of the asserts to proper error handling and reporting.

Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/tests/extent-map-tests.c