Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Marco Bubke
flatpak-qt-creator
Commits
706a04c6
Commit
706a04c6
authored
Nov 03, 2010
by
Christian Kandeler
Browse files
SSH: Ignore incoming data after requesting to close an SFTP channel.
parent
ea595696
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/plugins/coreplugin/ssh/sftpchannel.cpp
View file @
706a04c6
...
...
@@ -214,6 +214,8 @@ SftpJobId SftpChannelPrivate::createJob(const AbstractSftpOperation::Ptr &job)
void
SftpChannelPrivate
::
handleChannelSuccess
()
{
if
(
channelState
()
==
CloseRequested
)
return
;
#ifdef CREATOR_SSH_DEBUG
qDebug
(
"sftp subsystem initialized"
);
#endif
...
...
@@ -223,6 +225,9 @@ void SftpChannelPrivate::handleChannelSuccess()
void
SftpChannelPrivate
::
handleChannelFailure
()
{
if
(
channelState
()
==
CloseRequested
)
return
;
if
(
m_sftpState
!=
SubsystemRequested
)
{
throw
SSH_SERVER_EXCEPTION
(
SSH_DISCONNECT_PROTOCOL_ERROR
,
"Unexpected SSH_MSG_CHANNEL_FAILURE packet."
);
...
...
@@ -233,6 +238,9 @@ void SftpChannelPrivate::handleChannelFailure()
void
SftpChannelPrivate
::
handleChannelDataInternal
(
const
QByteArray
&
data
)
{
if
(
channelState
()
==
CloseRequested
)
return
;
m_incomingData
+=
data
;
m_incomingPacket
.
consumeData
(
m_incomingData
);
while
(
m_incomingPacket
.
isComplete
())
{
...
...
@@ -764,6 +772,9 @@ SftpChannelPrivate::JobMap::Iterator SftpChannelPrivate::lookupJob(SftpJobId id)
void
SftpChannelPrivate
::
closeHook
()
{
m_jobs
.
clear
();
m_incomingData
.
clear
();
m_incomingPacket
.
clear
();
emit
closed
();
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment