From adf1a2c3777ce1d6a75d903c2513ee4d1ae5e245 Mon Sep 17 00:00:00 2001 From: afederici <ajf5@illinois.edu> Date: Sat, 21 Nov 2020 14:52:57 -0600 Subject: [PATCH] logging --- inc/FileObject.h | 1 + src/TcpSocket.cpp | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/inc/FileObject.h b/inc/FileObject.h index b3b8a8a..059190e 100644 --- a/inc/FileObject.h +++ b/inc/FileObject.h @@ -4,6 +4,7 @@ #include <iostream> #include <string> #include <stdio.h> +#include <string.h> #include <stdlib.h> #include <fstream> #include <unistd.h> diff --git a/src/TcpSocket.cpp b/src/TcpSocket.cpp index d69112b..c2a9b96 100644 --- a/src/TcpSocket.cpp +++ b/src/TcpSocket.cpp @@ -145,7 +145,7 @@ void TcpSocket::sendLines(string ip, string port, string execfile, string readfi perror("send"); } sleep(1); - ifstream file(getMostRecentFile(readfile)); + ifstream file(getMostRecentFile(readfile).c_str()); string str; while (getline(file, str)) { -- GitLab