| 138 | */ |
| 139 | |
| 140 | int exec_check |
| 141 | ( |
| 142 | string const * command, |
| 143 | LIST * * pShell, |
| 144 | int32_t * error_length, |
| 145 | int32_t * error_max_length |
| 146 | ) |
| 147 | { |
| 148 | int const is_raw_cmd = is_raw_command_request( *pShell ); |
| 149 | |
| 150 | /* We allow empty commands for non-default shells since we do not really |
| 151 | * know what they are going to do with such commands. |
| 152 | */ |
| 153 | if ( !command->size && ( is_raw_cmd || list_empty( *pShell ) ) ) |
| 154 | return EXEC_CHECK_NOOP; |
| 155 | |
| 156 | return is_raw_cmd |
| 157 | ? EXEC_CHECK_OK |
| 158 | : check_cmd_for_too_long_lines( command->value, shell_maxline(), error_length, |
| 159 | error_max_length ); |
| 160 | } |
| 161 | |
| 162 | |
| 163 | /* |
nothing calls this directly
no test coverage detected