Error: attempt to read uninitilised memory location

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

Error: attempt to read uninitilised memory location

329 次查看
AW60
Contributor I

I have defined one global variable in one .C file and incrementing in in that file. This variable i am reading in other .C file. But when i simulate program in CW it gives above error. How to solve this? I

标签 (1)
标记 (1)
0 项奖励
1 回复

265 次查看
CrasyCat
Specialist III

Hello

 

- Which CPU are you targeting (HC08, HC12, Coldfire, ..)
- Which version of CodeWarrior are you using?
  To retrieve that info:
    - Start CodeWarrior
    - Select Help -> About Freescale CodeWarrior
    - Click on "Install Products"
    - CodeWarrior version used is displayed on top in the Installed Products dialog.

 

This message indicates you are attempting to read the variable value before the variable is ever initialized.

There are ways to prevent that but I need to know the answer to above questions to assist.

 

CrasyCat

0 项奖励