diff options
| -rw-r--r-- | ext/openssl/openssl.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/openssl/openssl.c b/ext/openssl/openssl.c index 781a6e6cbd..e6553786c2 100644 --- a/ext/openssl/openssl.c +++ b/ext/openssl/openssl.c @@ -1743,7 +1743,7 @@ static int php_openssl_make_REQ(struct php_x509_request * req, X509_REQ * csr, z len = 200; } memcpy(buffer, type, len); - buffer[len] = '\0'; + buffer[len - 1] = '\0'; type = buffer; /* Skip past any leading X. X: X, etc to allow for multiple |
