From 1c73c39715819eb521983a7832d3a60680266561 Mon Sep 17 00:00:00 2001 From: pehladik Date: Mon, 30 Mar 2020 17:10:56 +0200 Subject: [PATCH] fix close --- software/raspberry/superviseur-robot/lib/comrobot.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/software/raspberry/superviseur-robot/lib/comrobot.cpp b/software/raspberry/superviseur-robot/lib/comrobot.cpp index 904f0ba..cd1c2f8 100644 --- a/software/raspberry/superviseur-robot/lib/comrobot.cpp +++ b/software/raspberry/superviseur-robot/lib/comrobot.cpp @@ -131,7 +131,11 @@ int ComRobot::Open(string usart) { * @return Success if above 0, failure if below 0 */ int ComRobot::Close() { +#ifdef __SIMULATION__ + return close(sock); +#elif return close(fd); +#endif } /**