pnoltes commented on code in PR #851:
URL: https://github.com/apache/celix/pull/851#discussion_r4238650652


##########
bundles/shell/remote_shell/src/remote_shell.c:
##########
@@ -175,24 +175,32 @@ void *remoteShell_connection_run(void *data) {
                        char buff[COMMAND_BUFF_SIZE];
 
                        len = recv(fd, buff, COMMAND_BUFF_SIZE - 1, 0);
-                       if (len < COMMAND_BUFF_SIZE) {
-                               celix_status_t commandStatus = CELIX_SUCCESS;
-                               buff[len] = '\0';
-
-                               commandStatus = 
remoteShell_connection_execute(connection, buff);
-
-                               if (commandStatus == CELIX_SUCCESS) {
-                                       
remoteShell_connection_print(connection, RS_PROMPT);
-                               } else if (commandStatus == 
CELIX_FILE_IO_EXCEPTION) {
-                                       //exit command
-                                       break;
-                               } else { //error
-                                       
remoteShell_connection_print(connection, RS_ERROR);
-                                       
remoteShell_connection_print(connection, RS_PROMPT);
+                       if (len > 0) {
+                               if (len < COMMAND_BUFF_SIZE) {

Review Comment:
   updated the read for remote shell and applied to same pattern to rsa and 
http admin



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to