forked from epics_driver_modules/motorBase
temporary fix for ftp communication to xps from fast machines. Previously it
was cutting the messages short, this fix waits for the xps to respond fully to the FIRST command before continuing. This needs to be done properly in other places
This commit is contained in:
@@ -46,8 +46,10 @@ int ftpConnect (char* ip, char* login, char* password, int* socketFD)
|
||||
if (connect(sockFD, (struct sockaddr *)&sockAddr, sizeof(sockAddr)) < 0)
|
||||
return -1;
|
||||
|
||||
|
||||
receivedBytes = recv(sockFD, returnString, RETURN_SIZE, 0);
|
||||
do {
|
||||
receivedBytes = recv(sockFD, returnString, RETURN_SIZE, 0);
|
||||
}
|
||||
while (strchr(returnString,'\n')==NULL);
|
||||
|
||||
/* login */
|
||||
sprintf(command, "USER %s", login);
|
||||
|
||||
Reference in New Issue
Block a user