mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-04-21 03:10:02 +02:00
copying binary not done properly
This commit is contained in:
parent
93a86324fb
commit
fa822634aa
@ -527,7 +527,7 @@ int writeBinaryFile(char *mess, char *fname, char *buffer,
|
||||
if ((unitSize + bytesWritten) > filesize) {
|
||||
writeSize = filesize - bytesWritten;
|
||||
}
|
||||
size_t bytes = fwrite(buffer, 1, writeSize, fp);
|
||||
size_t bytes = fwrite((buffer + bytesWritten, 1, writeSize, fp);
|
||||
|
||||
// write
|
||||
if (bytes != (size_t)writeSize) {
|
||||
@ -543,6 +543,7 @@ int writeBinaryFile(char *mess, char *fname, char *buffer,
|
||||
LOG(logDEBUG1,
|
||||
("bytesWritten:%lu filesize:%lu\n", bytesWritten, filesize));
|
||||
}
|
||||
printf("\n");
|
||||
if (fclose(fp) != 0) {
|
||||
sprintf(mess,
|
||||
"Could not copy detector server. (closing file pointer)\n");
|
||||
|
Loading…
x
Reference in New Issue
Block a user