Github user mike-jumper commented on a diff in the pull request:

    https://github.com/apache/guacamole-server/pull/156#discussion_r178483146
  
    --- Diff: src/protocols/ssh/ssh.c ---
    @@ -296,9 +301,15 @@ void* ssh_client_thread(void* data) {
     
         }
     
    +    /* Set up the ttymode array prior to requesting the PTY */
    +    if (guac_ssh_ttymodes_init(ssh_ttymodes, sizeof(ssh_ttymodes),
    +            num_tty_opcodes, (guac_ssh_ttymode){ GUAC_SSH_TTY_OP_VERASE, 
settings->backspace}))
    --- End diff --
    
    Looking at the source for `guac_ssh_ttymodes_init()`, doesn't this need to 
be a pointer to a `guac_ssh_ttymode`? ie: `&((guac_ssh_ttymode) { 
GUAC_SSH_TTY_OP_VERASE, settings->backspace })` ?
    
    Alternatively, there's no need for all these parameters to be of the same 
type. It would also be possible to do something like:
    
        if (guac_ssh_ttymodes_init(ssh_ttymodes, sizeof(ssh_ttymodes),
                GUAC_SSH_TTY_OP_VERASE, settings->backspace, 
GUAC_SSH_TTY_OP_END))
    
    The code is your oyster.


---

Reply via email to