aboutsummaryrefslogtreecommitdiffstats
path: root/P1/src
diff options
context:
space:
mode:
Diffstat (limited to 'P1/src')
-rw-r--r--P1/src/mapper.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/P1/src/mapper.c b/P1/src/mapper.c
index 4a1bf1b..dfb6d22 100644
--- a/P1/src/mapper.c
+++ b/P1/src/mapper.c
@@ -100,15 +100,16 @@ void map(char *chunkData){
// poops the data out into separate .txt files named after the word
void writeIntermediateDS() {
intermediateDS *tempNode = &DS;
- valueList *tempNode2;
+ valueList *tempNode2 = tempNode -> value;
while(tempNode != NULL) {
// Get string of 1's associated with the word
char ones[100];
tempNode2 = tempNode2 -> value;
while(tempNode2 != NULL) {
+ printf("This loop is being run\n");
strcat(ones, "1 ");
- tempNode2 = tempNode -> next;
+ tempNode2 = tempNode2 -> next;
}
// Shove word and ones in a file named word.txt