From d454ed1a5bd98dd6777a7c8424e0c21d39684cb2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=89der=20Ferreira=20Zulian?= Date: Tue, 2 Jun 2015 17:56:57 +0200 Subject: [PATCH 1/2] Memory leak fixed. --- dram/src/simulation/MemoryManager.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/dram/src/simulation/MemoryManager.cpp b/dram/src/simulation/MemoryManager.cpp index a00e4cf4..48611d40 100644 --- a/dram/src/simulation/MemoryManager.cpp +++ b/dram/src/simulation/MemoryManager.cpp @@ -75,6 +75,8 @@ gp* MemoryManager::allocate() void MemoryManager::free(gp* payload) { + unsigned char *dptr = payload->get_data_ptr(); + delete[] dptr; payload->reset(); //clears all extensions freePayloads.push_back(payload); } From 9998400a5d3ed75e7503edd3dba75f541276d19f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=89der=20Ferreira=20Zulian?= Date: Tue, 2 Jun 2015 17:58:12 +0200 Subject: [PATCH 2/2] Readme file updated with information for syncng a fork to the main repo. after pull request approval. Other cosmetic changes: - removal of unused headers; - space deletion. --- README.md | 10 ++++++++++ dram/src/simulation/SimulationManager.cpp | 2 +- dram/src/simulation/main.cpp | 4 +--- 3 files changed, 12 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 990ebf1f..751aff48 100644 --- a/README.md +++ b/README.md @@ -38,6 +38,16 @@ your changes to the official codebase. $ git clone --recursive https://@git.rhrk.uni-kl.de//dram.vp.system.git ``` +After a pull request being accepted and merged into the official repository +you should get your fork updated. + +``` bash +$ git fetch upstream +$ git checkout master +$ git merge upstream/master +$ git push origin HEAD +``` + After cloning go to the project directory. ``` bash diff --git a/dram/src/simulation/SimulationManager.cpp b/dram/src/simulation/SimulationManager.cpp index f463f23a..396619ad 100644 --- a/dram/src/simulation/SimulationManager.cpp +++ b/dram/src/simulation/SimulationManager.cpp @@ -1,4 +1,4 @@ - /* +/* * Copyright (c) 2015, University of Kaiserslautern * All rights reserved. * diff --git a/dram/src/simulation/main.cpp b/dram/src/simulation/main.cpp index 04f08f0b..0c160654 100644 --- a/dram/src/simulation/main.cpp +++ b/dram/src/simulation/main.cpp @@ -36,13 +36,11 @@ #include #include -#include "SimulationManager.h" -#include "../controller/core/configuration/Configuration.h" - #include #include #include +#include "SimulationManager.h" using namespace std;