Commit 2c3dd4ff595e604cd4c4c51cff7a208f23148c2d

Authored by Alex Elder
1 parent cc344fa1b5

ceph: eliminate sparse warnings in fs code

Fix the causes for sparse warnings reported in the ceph file system
code.  Here there are only two (and they're sort of silly but
they're easy to fix).

This partially resolves:
    http://tracker.ceph.com/issues/4184

Reported-by: Fengguang Wu <fengguang.wu@intel.com>
Signed-off-by: Alex Elder <elder@inktank.com>
Reviewed-by: Josh Durgin <josh.durgin@inktank.com>

Showing 1 changed file with 2 additions and 2 deletions Side-by-side Diff

... ... @@ -213,7 +213,7 @@
213 213 XATTR_NAME_CEPH(dir, rsubdirs),
214 214 XATTR_NAME_CEPH(dir, rbytes),
215 215 XATTR_NAME_CEPH(dir, rctime),
216   - { 0 } /* Required table terminator */
  216 + { .name = NULL, 0 } /* Required table terminator */
217 217 };
218 218 static size_t ceph_dir_vxattrs_name_size; /* total size of all names */
219 219  
... ... @@ -232,7 +232,7 @@
232 232 XATTR_LAYOUT_FIELD(file, layout, stripe_count),
233 233 XATTR_LAYOUT_FIELD(file, layout, object_size),
234 234 XATTR_LAYOUT_FIELD(file, layout, pool),
235   - { 0 } /* Required table terminator */
  235 + { .name = NULL, 0 } /* Required table terminator */
236 236 };
237 237 static size_t ceph_file_vxattrs_name_size; /* total size of all names */
238 238