From cf96545f6097265281691c80a7c2da7fc0a1a798 Mon Sep 17 00:00:00 2001 From: Dhanya Thattil Date: Thu, 2 Sep 2021 16:52:13 +0200 Subject: [PATCH] wip --- .../slsDetectorServer/src/slsDetectorServer_funcs.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/slsDetectorServers/slsDetectorServer/src/slsDetectorServer_funcs.c b/slsDetectorServers/slsDetectorServer/src/slsDetectorServer_funcs.c index a094a1953..29a05bf99 100644 --- a/slsDetectorServers/slsDetectorServer/src/slsDetectorServer_funcs.c +++ b/slsDetectorServers/slsDetectorServer/src/slsDetectorServer_funcs.c @@ -3725,7 +3725,8 @@ int program_fpga(int file_des) { return printSocketReadError(); LOG(logINFOBLUE, ("Program size is: %lld\n", (long long unsigned int)filesize)); - fpgasrc = malloc(filesize); + int fsize = filesize; + fpgasrc = malloc(fsize); if (fpgasrc == NULL) { LOG(logERROR, ("Could not malloc\n")); ret = FAIL;