null pointer is dereferenced

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

null pointer is dereferenced

1,129 次查看
ayaserry
Contributor I

If an uninitialized pointer or initialized by null pointer is dereferenced, the simulator will continue the execution without firing an error. Is there an option to fire error or crash while trying to execute the line of the dereferencing? 

 

Details: - CodeWarrior HCS12 V4.7- Compiler: chc12 compiler - Linker: linker.exe  - Simulator: hiwave.exe

标签 (1)
3 回复数

1,017 次查看
TICS_Fiona
NXP Employee
NXP Employee

I found a same question from you in SR#1-3896475401, and it is under processing by our engineer.

Fiona Kuang

Technical Information & Commercial Support

-----------------------------------------------------------------------------------------------------------------------

Note: If this post answers your question, please click the Correct Answer button. Thank you!

-----------------------------------------------------------------------------------------------------------------------

0 项奖励
回复

1,017 次查看
ayaserry
Contributor I

could you please give me this SR? I can't reach it.

0 项奖励
回复

1,017 次查看
ZhangJennie
NXP TechSupport
NXP TechSupport

Hi,

No matter you use commandline or CW IDE, add –WmsgSe5651 as a compiler commandline parameter, this should also do the same functionality.

then CW compiler will produce C5651 error about  Null pointer be not initialized.

Can you try it? how does it work?


Have a great day,
Zhang Jun

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 项奖励
回复