GUACAMOLE-257: Set VNC/SSH file upload handlers only if SFTP is enabled.

This commit is contained in:
Michael Jumper 2017-03-28 10:48:38 -07:00
parent 039a1c52e4
commit 61896e829c
2 changed files with 4 additions and 2 deletions

View File

@ -87,6 +87,7 @@ int guac_ssh_user_join_handler(guac_user* user, int argc, char** argv) {
user->size_handler = guac_ssh_user_size_handler; user->size_handler = guac_ssh_user_size_handler;
/* Set generic (non-filesystem) file upload handler */ /* Set generic (non-filesystem) file upload handler */
if (settings->enable_sftp)
user->file_handler = guac_sftp_file_handler; user->file_handler = guac_sftp_file_handler;
} }

View File

@ -98,6 +98,7 @@ int guac_vnc_user_join_handler(guac_user* user, int argc, char** argv) {
#ifdef ENABLE_COMMON_SSH #ifdef ENABLE_COMMON_SSH
/* Set generic (non-filesystem) file upload handler */ /* Set generic (non-filesystem) file upload handler */
if (settings->enable_sftp)
user->file_handler = guac_vnc_sftp_file_handler; user->file_handler = guac_vnc_sftp_file_handler;
#endif #endif