Skip to content

[Coverity CID: 220534] Out-of-bounds access in tests/arch/arm/arm_no_multithreading/src/main.c #34007

@zephyrbot

Description

@zephyrbot

Static code scan issues found in file:

https://github.com/zephyrproject-rtos/zephyr/tree/b86f7addae05add0db45d9b528854235fbb93a48/tests/arch/arm/arm_no_multithreading/src/main.c#L104

Category: Memory - corruptions
Function: test_main
Component: Tests
CID: 220534

Details:

arch_irq_connect_dynamic(i, 0 /* highest priority */,

98    
99         __ASSERT(i >= 0,
100             "No available IRQ line to use in the test\n");
101    
102         printk("Available IRQ line: %u\n", i);
103    
>>>     CID 220534:  Memory - corruptions  (OVERRUN)
>>>     Overrunning callee's array of size 128 by passing argument "i" (which evaluates to 4294967295) in call to "arch_irq_connect_dynamic".
104         arch_irq_connect_dynamic(i, 0 /* highest priority */,
105             arm_isr_handler,
106             NULL,
107             0);
108    
109         NVIC_EnableIRQ(i);

Please fix or provide comments in coverity using the link:

https://scan9.coverity.com/reports.htm#v29271/p12996

Note: This issue was created automatically. Priority was set based on classification
of the file affected and the impact field in coverity. Assignees were set using the CODEOWNERS file.

Metadata

Metadata

Assignees

Labels

CoverityA Coverity detected issue or its fixbugThe issue is a bug, or the PR is fixing a bugpriority: lowLow impact/importance bug

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions