Commit 8738b038 authored by Alexandre Julliard's avatar Alexandre Julliard

crypt32: Increase buffer size to silence a gcc warning.

parent 9944b97a
...@@ -3534,11 +3534,11 @@ static BOOL WINAPI CRYPT_AsnEncodeUtcTime(DWORD dwCertEncodingType, ...@@ -3534,11 +3534,11 @@ static BOOL WINAPI CRYPT_AsnEncodeUtcTime(DWORD dwCertEncodingType,
__TRY __TRY
{ {
SYSTEMTIME sysTime; SYSTEMTIME sysTime;
/* sorry, magic number: enough for tag, len, YYMMDDHHMMSSZ\0. I use a /* sorry, magic number: enough for tag, len, YYMMDDHHMMSSZ. I use a
* temporary buffer because the output buffer is not NULL-terminated. * temporary buffer because the output buffer is not NULL-terminated.
*/ */
char buf[16]; static const DWORD bytesNeeded = 15;
static const DWORD bytesNeeded = sizeof(buf) - 1; char buf[40];
if (!pbEncoded) if (!pbEncoded)
{ {
...@@ -3591,11 +3591,11 @@ static BOOL CRYPT_AsnEncodeGeneralizedTime(DWORD dwCertEncodingType, ...@@ -3591,11 +3591,11 @@ static BOOL CRYPT_AsnEncodeGeneralizedTime(DWORD dwCertEncodingType,
__TRY __TRY
{ {
SYSTEMTIME sysTime; SYSTEMTIME sysTime;
/* sorry, magic number: enough for tag, len, YYYYMMDDHHMMSSZ\0. I use a /* sorry, magic number: enough for tag, len, YYYYMMDDHHMMSSZ. I use a
* temporary buffer because the output buffer is not NULL-terminated. * temporary buffer because the output buffer is not NULL-terminated.
*/ */
char buf[18]; static const DWORD bytesNeeded = 17;
static const DWORD bytesNeeded = sizeof(buf) - 1; char buf[40];
if (!pbEncoded) if (!pbEncoded)
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment