PPC: Add place for NULL chars in intrnames
In a corner case we could fall into OOB error. Authored by: Patryk Duda <pdk@semihalf.com> Submitted by: Wojciech Macek <wma@semihalf.com> Obtained from: Semihalf Sponsored by: IBM, QCM Technologies
This commit is contained in:
parent
53c2c7918d
commit
919736d252
@ -130,7 +130,7 @@ static u_int nirqs = 0; /* Allocated IRQs. */
|
||||
static u_int stray_count;
|
||||
|
||||
u_long intrcnt[INTR_VECTORS];
|
||||
char intrnames[INTR_VECTORS * MAXCOMLEN];
|
||||
char intrnames[INTR_VECTORS * (MAXCOMLEN + 1)];
|
||||
size_t sintrcnt = sizeof(intrcnt);
|
||||
size_t sintrnames = sizeof(intrnames);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user