File tree Expand file tree Collapse file tree 2 files changed +16
-1
lines changed Expand file tree Collapse file tree 2 files changed +16
-1
lines changed Original file line number Diff line number Diff line change 1
1
[package ]
2
2
name = " libssh-rs"
3
- version = " 0.3.5 "
3
+ version = " 0.3.6 "
4
4
edition = " 2018"
5
5
repository = " https://github.com/wez/libssh-rs"
6
6
description = " Bindings to the libssh library"
Original file line number Diff line number Diff line change @@ -1169,6 +1169,21 @@ impl Session {
1169
1169
sftp. init ( ) ?;
1170
1170
Ok ( sftp)
1171
1171
}
1172
+
1173
+ /// Send a message that should be ignored by the peer
1174
+ pub fn send_ignore ( & self , data : & [ u8 ] ) -> SshResult < ( ) > {
1175
+ let sess = self . lock_session ( ) ;
1176
+ let status = unsafe { sys:: ssh_send_ignore ( * * sess, data. as_ptr ( ) as _ ) } ;
1177
+ if status != sys:: SSH_OK as i32 {
1178
+ if let Some ( err) = sess. last_error ( ) {
1179
+ Err ( err)
1180
+ } else {
1181
+ Err ( Error :: TryAgain )
1182
+ }
1183
+ } else {
1184
+ Ok ( ( ) )
1185
+ }
1186
+ }
1172
1187
}
1173
1188
1174
1189
#[ cfg( unix) ]
You can’t perform that action at this time.
0 commit comments