aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatt Strapp <strap012@umn.edu>2020-11-02 19:19:57 -0600
committerMatt Strapp <strap012@umn.edu>2020-11-02 19:19:57 -0600
commitcb5a637edea9777eab7baeaa3cfac3cb1a72f87a (patch)
tree4ab022f6e528b4a02bfc289eff6e7d505af0720d
parentget rid of comment (diff)
downloadcsci4061-cb5a637edea9777eab7baeaa3cfac3cb1a72f87a.tar
csci4061-cb5a637edea9777eab7baeaa3cfac3cb1a72f87a.tar.gz
csci4061-cb5a637edea9777eab7baeaa3cfac3cb1a72f87a.tar.bz2
csci4061-cb5a637edea9777eab7baeaa3cfac3cb1a72f87a.tar.lz
csci4061-cb5a637edea9777eab7baeaa3cfac3cb1a72f87a.tar.xz
csci4061-cb5a637edea9777eab7baeaa3cfac3cb1a72f87a.tar.zst
csci4061-cb5a637edea9777eab7baeaa3cfac3cb1a72f87a.zip
still doesn't work
Diffstat (limited to '')
-rw-r--r--P2/lib/utils.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/P2/lib/utils.c b/P2/lib/utils.c
index ca59f51..e0f087e 100644
--- a/P2/lib/utils.c
+++ b/P2/lib/utils.c
@@ -40,13 +40,13 @@ void sendChunkData(char *inputFile, int nMappers) {
while(fgets(message.msgText, chunkSize + 1, file) != NULL) {
// TODO! help
- int i = 1023;
+ int i = 1024;
while(validChar(message.msgText[i])) {
- message.msgText[i--] == '\0';
- // i--;
+ message.msgText[i] == '\0';
+ i--;
// printf("%d\n", i);
}
- fseek(file, (i - 1023), SEEK_CUR);
+ fseek(file, (i - 1024), SEEK_CUR);
printf("%s\n", message.msgText);
message.msgType = (map++ % nMappers) + 1 ;
//THIS IS DEBUG, NOT ACTUALLY FUNCTIONAL (like at all)