Hi,

On 4 Oct, 2013, at 5:29 PM, nikic <notifications@github.com> wrote:

> In ext/openssl/openssl.c:
> 
> > +	} else if (!X509_digest(peer, mdtype, md, &n)) {
> > +		php_error_docref(NULL TSRMLS_CC, E_ERROR, "Could not generate signature");
> > +		return 0;
> > +	}
> > +
> > +	if (raw) {
> > +		*out_len = n;
> > +		*out = estrndup(md, n);
> > +	} else {
> > +		*out_len = n * 2;
> > +		*out = emalloc(*out_len + 1);
> > +
> > +		make_digest_ex(*out, md, n);
> > +	}
> > +
> > +	return 1;
> To add to that, parameters and return values that are boolean should be denoted as such, e.g. the raw parameter here and the return value of match should be zend_bool. Furthermore I'd suggest to use minimal necessary amount of indirection, e.g. the zval **val argument of match could just as well be zval *val unless I'm missing something.
> 
Thanks for reviewing the code, I'll make the changes when I'm hooked up to the "real" Internet again :)

> —
> Reply to this email directly or view it on GitHub.