aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--P2/lib/utils.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/P2/lib/utils.c b/P2/lib/utils.c
index da250dc..b9d4be6 100644
--- a/P2/lib/utils.c
+++ b/P2/lib/utils.c
@@ -46,6 +46,8 @@ void sendChunkData(char *inputFile, int nMappers) {
struct msgBuffer message = makeMessage();
// open message queue
int msgid = openQueue();
+ closeQueue(msgid);
+ msgid = openQueue();
// DEBUG! Remove if already exists when opening queue for the first time
int map = 0;
FILE* file = fopen(inputFile, "r");