Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Avoid using memset to initialize structs.
[simgrid.git] / src / kernel / routing / NetZoneImpl.cpp
index a9e952e..9609323 100644 (file)
@@ -315,8 +315,7 @@ bool NetZoneImpl::getBypassRoute(routing::NetPoint* src, routing::NetPoint* dst,
 void NetZoneImpl::getGlobalRoute(routing::NetPoint* src, routing::NetPoint* dst,
                                  /* OUT */ std::vector<surf::LinkImpl*>* links, double* latency)
 {
-  s_sg_platf_route_cbarg_t route;
-  memset(&route, 0, sizeof(route));
+  s_sg_platf_route_cbarg_t route{};
 
   XBT_DEBUG("Resolve route from '%s' to '%s'", src->getCname(), dst->getCname());