X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/183a6118a95c570b0c66695505dab7dbebc0c7b3..2f3bc1bedb87e982714241309c59180d10d87c94:/src/surf/StorageImpl.cpp diff --git a/src/surf/StorageImpl.cpp b/src/surf/StorageImpl.cpp index a6b13179b0..95c0ffe301 100644 --- a/src/surf/StorageImpl.cpp +++ b/src/surf/StorageImpl.cpp @@ -64,11 +64,11 @@ StorageImpl::StorageImpl(Model* model, const char* name, lmm_system_t maxminSyst , piface_(this) , size_(size) , usedSize_(0) - , typeId_(xbt_strdup(type_id)) + , typeId_(type_id) + , attach_(attach) , writeActions_(std::vector()) { content_ = parseContent(content_name); - attach_ = attach; turnOn(); XBT_DEBUG("Create resource with Bread '%f' Bwrite '%f' and Size '%llu'", bread, bwrite, size); constraintRead_ = lmm_constraint_new(maxminSystem, this, bread); @@ -81,8 +81,6 @@ StorageImpl::~StorageImpl() storageDestructedCallbacks(this); if (content_ != nullptr) delete content_; - - free(typeId_); } std::map* StorageImpl::parseContent(const char* filename)