mirror of
https://github.com/php-gnupg/php-gnupg.git
synced 2024-12-23 02:11:40 +00:00
Use fixed PHPC_HASH_CSTR_ADD_PTR
This commit is contained in:
parent
bc39172174
commit
f89f8d9411
3 changed files with 3 additions and 4 deletions
4
gnupg.c
4
gnupg.c
|
@ -758,7 +758,7 @@ PHP_FUNCTION(gnupg_addsignkey)
|
|||
gpgme_subkey = gpgme_key->subkeys;
|
||||
while (gpgme_subkey) {
|
||||
if (gpgme_subkey->can_sign == 1) {
|
||||
PHPC_HASH_CSTR_ADD_PTR(PHPC_THIS->signkeys, gpgme_subkey->keyid, passphrase);
|
||||
PHPC_HASH_CSTR_ADD_PTR(PHPC_THIS->signkeys, gpgme_subkey->keyid, passphrase, passphrase_len + 1);
|
||||
}
|
||||
gpgme_subkey = gpgme_subkey->next;
|
||||
}
|
||||
|
@ -801,7 +801,7 @@ PHP_FUNCTION(gnupg_adddecryptkey)
|
|||
gpgme_subkey = gpgme_key->subkeys;
|
||||
while (gpgme_subkey) {
|
||||
if (gpgme_subkey->secret == 1) {
|
||||
PHPC_HASH_CSTR_ADD_PTR(PHPC_THIS->decryptkeys, gpgme_subkey->keyid, passphrase);
|
||||
PHPC_HASH_CSTR_ADD_PTR(PHPC_THIS->decryptkeys, gpgme_subkey->keyid, passphrase, passphrase_len + 1);
|
||||
}
|
||||
gpgme_subkey = gpgme_subkey->next;
|
||||
}
|
||||
|
|
2
phpc
2
phpc
|
@ -1 +1 @@
|
|||
Subproject commit 3cc9a2fe8b23f4ff95bc650fc9ac66f92905621f
|
||||
Subproject commit 6b7438355cfda1ed3e4895f21686914b794671d0
|
|
@ -9,7 +9,6 @@ $gpg = new gnupg();
|
|||
$gpg -> seterrormode(gnupg::ERROR_WARNING);
|
||||
$gpg -> addencryptkey($fingerprint);
|
||||
$enc = $gpg -> encrypt($plaintext);
|
||||
|
||||
$gpg = NULL;
|
||||
|
||||
$gpg = new gnupg();
|
||||
|
|
Loading…
Reference in a new issue