diff options
author | Sage Weil <sage@inktank.com> | 2012-09-24 20:59:48 -0700 |
---|---|---|
committer | Alex Elder <elder@inktank.com> | 2012-10-01 17:20:00 -0500 |
commit | d63b77f4c552cc3a20506871046ab0fcbc332609 (patch) | |
tree | a428fe42c092c0f6126a99fbc788ae96e8922a97 /include/linux/ceph/osd_client.h | |
parent | b905a7f8b7a61c192927d0324f2ea6c998f451ba (diff) | |
download | blackbird-obmc-linux-d63b77f4c552cc3a20506871046ab0fcbc332609.tar.gz blackbird-obmc-linux-d63b77f4c552cc3a20506871046ab0fcbc332609.zip |
libceph: check for invalid mapping
If we encounter an invalid (e.g., zeroed) mapping, return an error
and avoid a divide by zero.
Signed-off-by: Sage Weil <sage@inktank.com>
Reviewed-by: Alex Elder <elder@inktank.com>
Diffstat (limited to 'include/linux/ceph/osd_client.h')
-rw-r--r-- | include/linux/ceph/osd_client.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/ceph/osd_client.h b/include/linux/ceph/osd_client.h index cedfb1a8434a..d9b880e977e6 100644 --- a/include/linux/ceph/osd_client.h +++ b/include/linux/ceph/osd_client.h @@ -207,7 +207,7 @@ extern void ceph_osdc_handle_reply(struct ceph_osd_client *osdc, extern void ceph_osdc_handle_map(struct ceph_osd_client *osdc, struct ceph_msg *msg); -extern void ceph_calc_raw_layout(struct ceph_osd_client *osdc, +extern int ceph_calc_raw_layout(struct ceph_osd_client *osdc, struct ceph_file_layout *layout, u64 snapid, u64 off, u64 *plen, u64 *bno, |