mirror of
https://github.com/clearml/dropbear
synced 2025-01-31 10:57:01 +00:00
Avoid gnu extension conditional operator
This commit is contained in:
parent
80e9281701
commit
17873e8c92
@ -693,7 +693,11 @@ static int sessioncommand(struct Channel *channel, struct ChanSess *chansess,
|
|||||||
|
|
||||||
/* take global command into account */
|
/* take global command into account */
|
||||||
if (svr_opts.forced_command) {
|
if (svr_opts.forced_command) {
|
||||||
chansess->original_command = chansess->cmd ? : m_strdup("");
|
if (chansess->cmd) {
|
||||||
|
chansess->original_command = chansess->cmd;
|
||||||
|
} else {
|
||||||
|
chansess->original_command = m_strdup("");
|
||||||
|
}
|
||||||
chansess->cmd = m_strdup(svr_opts.forced_command);
|
chansess->cmd = m_strdup(svr_opts.forced_command);
|
||||||
} else {
|
} else {
|
||||||
/* take public key option 'command' into account */
|
/* take public key option 'command' into account */
|
||||||
|
Loading…
Reference in New Issue
Block a user