Skip to content

Commit

Permalink
Merge pull request OpenMathLib#4523 from martin-frbg/gemmtstack
Browse files Browse the repository at this point in the history
Fix a potential buffer overflow in GEMMT
  • Loading branch information
martin-frbg committed Feb 25, 2024
2 parents f860e82 + baf8856 commit 07e62a4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions interface/gemmt.c
Original file line number Diff line number Diff line change
Expand Up @@ -522,7 +522,7 @@ void CNAME(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo,

IDEBUG_START;

buffer_size = j + k + 128 / sizeof(FLOAT);
buffer_size = 2 * (j + k) + 128 / sizeof(FLOAT);
#ifdef WINDOWS_ABI
buffer_size += 160 / sizeof(FLOAT);
#endif
Expand Down Expand Up @@ -611,7 +611,7 @@ void CNAME(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo,
#endif
IDEBUG_START;

buffer_size = j + k + 128 / sizeof(FLOAT);
buffer_size = 2 * (j + k) + 128 / sizeof(FLOAT);
#ifdef WINDOWS_ABI
buffer_size += 160 / sizeof(FLOAT);
#endif
Expand Down

0 comments on commit 07e62a4

Please sign in to comment.