dleehr / DLSFTPClient

SFTP Client library and sample app for iOS, using libssh2
BSD 2-Clause "Simplified" License
80 stars 35 forks source link

DLSFTPListFilesRequest buffer is not zeroed #16

Closed dleehr closed 10 years ago

dleehr commented 10 years ago

When listing directories, the buffer[cBufferSize] is used and reused without zeroing out. There seem to be some cases where the null terminator isn't caught when converting to NSString. Best to zero out the buffer on each loop or allocate the NSString with a fixed length (from result)

dleehr commented 10 years ago

Could be other cases like this in download files