| 169 | } |
| 170 | |
| 171 | static av_cold int libssh_close(URLContext *h) |
| 172 | { |
| 173 | LIBSSHContext *libssh = h->priv_data; |
| 174 | if (libssh->file) { |
| 175 | sftp_close(libssh->file); |
| 176 | libssh->file = NULL; |
| 177 | } |
| 178 | if (libssh->sftp) { |
| 179 | sftp_free(libssh->sftp); |
| 180 | libssh->sftp = NULL; |
| 181 | } |
| 182 | if (libssh->session) { |
| 183 | ssh_disconnect(libssh->session); |
| 184 | ssh_free(libssh->session); |
| 185 | libssh->session = NULL; |
| 186 | } |
| 187 | return 0; |
| 188 | } |
| 189 | |
| 190 | static av_cold int libssh_connect(URLContext *h, const char *url, char *path, size_t path_size) |
| 191 | { |
no outgoing calls
no test coverage detected