mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-05-02 22:25:04 -04:00
removed asserts and put proper error handling in compress.c
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@6937 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
162ef94b70
commit
3e88b54ae3
5 changed files with 278 additions and 232 deletions
|
@ -1139,7 +1139,12 @@ bool PGPHandler::encryptTextToFile(const PGPIdType& key_id,const std::string& te
|
|||
return false ;
|
||||
}
|
||||
|
||||
ops_encrypt_stream(info, public_key, NULL, ops_false, ops_true);
|
||||
if(!ops_encrypt_stream(info, public_key, NULL, ops_false, ops_true))
|
||||
{
|
||||
std::cerr << "PGPHandler::encryptTextToFile(): ERROR: encryption failed." << std::endl;
|
||||
return false ;
|
||||
}
|
||||
|
||||
ops_write(text.c_str(), text.length(), info);
|
||||
ops_teardown_file_write(info, fd);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue