suppaftp 4.1.2

This commit is contained in:
veeso
2021-08-23 12:20:25 +02:00
parent c49184dcb1
commit 7713c6c21d
4 changed files with 15 additions and 15 deletions

View File

@@ -35,7 +35,7 @@ Released on ??
- Updated `crossterm` to `0.20` - Updated `crossterm` to `0.20`
- Updated `open` to `2.0.1` - Updated `open` to `2.0.1`
- Added `tui-realm-stdlib 0.6.0` - Added `tui-realm-stdlib 0.6.0`
- Replaced `ftp4` with `suppaftp 4.1.1` - Replaced `ftp4` with `suppaftp 4.1.2`
- Updated `tui-realm` to `0.6.0` - Updated `tui-realm` to `0.6.0`
## 0.6.0 ## 0.6.0

4
Cargo.lock generated
View File

@@ -1324,9 +1324,9 @@ checksum = "6bdef32e8150c2a081110b42772ffe7d7c9032b606bc226c8260fd97e0976601"
[[package]] [[package]]
name = "suppaftp" name = "suppaftp"
version = "4.1.1" version = "4.1.2"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "6d8310cb2dcc312f9e941d35453a1b2cb654186f4ec60b02e2d778a221c3002b" checksum = "29a4d861acfdc117c6d373c3b743c534dbbbb2d782e7646b27439a7c5282ad6a"
dependencies = [ dependencies = [
"chrono", "chrono",
"lazy_static", "lazy_static",

View File

@@ -47,7 +47,7 @@ rpassword = "5.0.1"
serde = { version = "^1.0.0", features = [ "derive" ] } serde = { version = "^1.0.0", features = [ "derive" ] }
simplelog = "0.10.0" simplelog = "0.10.0"
ssh2 = "0.9.0" ssh2 = "0.9.0"
suppaftp = { version = "4.1.1", features = [ "secure" ] } suppaftp = { version = "4.1.2", features = [ "secure" ] }
tempfile = "3.1.0" tempfile = "3.1.0"
textwrap = "0.14.2" textwrap = "0.14.2"
thiserror = "^1.0.0" thiserror = "^1.0.0"

View File

@@ -36,7 +36,7 @@ use std::path::{Path, PathBuf};
use std::time::UNIX_EPOCH; use std::time::UNIX_EPOCH;
use suppaftp::native_tls::TlsConnector; use suppaftp::native_tls::TlsConnector;
use suppaftp::{ use suppaftp::{
list::{File, UnixPexQuery}, list::{File, PosixPexQuery},
status::FILE_UNAVAILABLE, status::FILE_UNAVAILABLE,
types::{FileType, Response}, types::{FileType, Response},
FtpError, FtpStream, FtpError, FtpStream,
@@ -164,19 +164,19 @@ impl FtpFileTransfer {
fn query_unix_pex(f: &File) -> (u8, u8, u8) { fn query_unix_pex(f: &File) -> (u8, u8, u8) {
( (
Self::pex_to_byte( Self::pex_to_byte(
f.can_read(UnixPexQuery::Owner), f.can_read(PosixPexQuery::Owner),
f.can_write(UnixPexQuery::Owner), f.can_write(PosixPexQuery::Owner),
f.can_execute(UnixPexQuery::Owner), f.can_execute(PosixPexQuery::Owner),
), ),
Self::pex_to_byte( Self::pex_to_byte(
f.can_read(UnixPexQuery::Group), f.can_read(PosixPexQuery::Group),
f.can_write(UnixPexQuery::Group), f.can_write(PosixPexQuery::Group),
f.can_execute(UnixPexQuery::Group), f.can_execute(PosixPexQuery::Group),
), ),
Self::pex_to_byte( Self::pex_to_byte(
f.can_read(UnixPexQuery::Others), f.can_read(PosixPexQuery::Others),
f.can_write(UnixPexQuery::Others), f.can_write(PosixPexQuery::Others),
f.can_execute(UnixPexQuery::Others), f.can_execute(PosixPexQuery::Others),
), ),
) )
} }
@@ -399,7 +399,7 @@ impl FileTransfer for FtpFileTransfer {
match &mut self.stream { match &mut self.stream {
Some(stream) => match stream.mkdir(&dir.as_path().to_string_lossy()) { Some(stream) => match stream.mkdir(&dir.as_path().to_string_lossy()) {
Ok(_) => Ok(()), Ok(_) => Ok(()),
Err(FtpError::InvalidResponse(Response { Err(FtpError::UnexpectedResponse(Response {
// Directory already exists // Directory already exists
code: FILE_UNAVAILABLE, code: FILE_UNAVAILABLE,
body: _, body: _,