[Delta] API question PKeyBase::decrypt()
justin-psi2 at affinix.com
Sat Apr 28 23:13:13 PDT 2007
On Saturday 28 April 2007 9:52 pm, Alon Bar-Lev wrote:
> On 4/29/07, Justin Karneges <justin-psi2 at affinix.com> wrote:
> > On Saturday 28 April 2007 10:57 am, Alon Bar-Lev wrote:
> > > Why is it takes pointer and not reference for out?
> > > virtual bool decrypt(const SecureArray &in, SecureArray *out,
> > > EncryptionAlgorithm alg);
> > Non-const references in arguments give the appearance of pass-by-value
> > when in fact the argument could be modified by the function. Pointers
> > aren't as ambiguous. This is a common C++ practice.
> So we it does not return the output like other functions, return empty if
> fails? I think this is the only one which is different from all the other
This one is different, because a decrypt could successfully result in an empty
answer. I think with the other operations this is not possible.
More information about the delta