| Index: net/ftp/ftp_directory_listing_buffer.cc
|
| diff --git a/net/ftp/ftp_directory_listing_buffer.cc b/net/ftp/ftp_directory_listing_buffer.cc
|
| index 030da83d7cd4c145ce1c7f2fecf2166a60c86403..830ec3b54688a11887c2edf1f31598971599d08a 100644
|
| --- a/net/ftp/ftp_directory_listing_buffer.cc
|
| +++ b/net/ftp/ftp_directory_listing_buffer.cc
|
| @@ -65,6 +65,9 @@ int FtpDirectoryListingBuffer::ProcessRemainingData() {
|
| if (rv != OK)
|
| return rv;
|
|
|
| + if (!buffer_.empty())
|
| + return ERR_INVALID_RESPONSE;
|
| +
|
| return ParseLines();
|
| }
|
|
|
| @@ -77,6 +80,10 @@ FtpDirectoryListingEntry FtpDirectoryListingBuffer::PopEntry() {
|
| return current_parser_->PopEntry();
|
| }
|
|
|
| +FtpServerType FtpDirectoryListingBuffer::GetServerType() const {
|
| + return (current_parser_ ? current_parser_->GetServerType() : SERVER_UNKNOWN);
|
| +}
|
| +
|
| bool FtpDirectoryListingBuffer::ConvertToDetectedEncoding(
|
| const std::string& from, string16* to) {
|
| std::string encoding(encoding_.empty() ? "ascii" : encoding_);
|
|
|