read GpgmeData

Florian Lindner mailinglists at xgm.de
Tue Apr 29 22:09:01 CEST 2003


Am Dienstag, 29. April 2003 20:33 schrieb Marcus Brinkmann:
> On Tue, Apr 29, 2003 at 06:11:54PM +0200, Florian Lindner wrote:
> > > > 	gpgme_data_new(&data);
> > > > 	gpgme_data_new_from_mem(&data, m_text.c_str(), m_text.size(), 1);
>
> you initialize data twice, and output not at all.

Ok, I've changed it to this:

	GpgmeData data, output;
	gpgme_data_new(&output);
	gpgme_data_new_from_mem(&data, m_text.c_str(), m_text.size(), 1);
	gpgme_op_encrypt(m_ctx, rec, data, output);

	gpgme_data_release(output);
	gpgme_data_release(data);
	gpgme_recipients_release(rec);
	return "";

But the error does not change.
Thx,
Florian




More information about the Gnupg-devel mailing list