]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mds: zero out the layout in handle_client_setlayout
authorGreg Farnum <gregf@hq.newdream.net>
Thu, 23 Sep 2010 23:36:37 +0000 (16:36 -0700)
committerSage Weil <sage@newdream.net>
Fri, 1 Oct 2010 23:21:50 +0000 (16:21 -0700)
Could have led to an invalid layout by mistake.

src/mds/Server.cc

index c2e83e8bcd0a0f455388a5763dffb0fff6cafb80..42db43bfd95bdb8b35b22c829154d9100524352c 100644 (file)
@@ -2910,6 +2910,7 @@ void Server::handle_client_setlayout(MDRequest *mdr)
   // validate layout
   // FIXME: only set striping parameters, for now.
   ceph_file_layout layout;
+  memset(&layout, 0, sizeof(layout));
 
   if (req->head.args.setlayout.layout.fl_object_size > 0)
     layout.fl_object_size = req->head.args.setlayout.layout.fl_object_size;