The problem
I've been coding a game in Microsoft Visual Studio 2010 Professional using C++ and Allegro 5.0.10 for the past year, and it's getting to the point where there isn't much left to do before release. However, when I build the game now, I run into random errors. By random errors, I mean sometimes the game runs without issue, and sometimes it begins to do things I haven't written into the code at all. Examples of this include displaying entire sprite sheets at (0,0); not moving the character, but changing the direction he/she is facing; moving the character one direction but displaying them walking the opposite way (think moonwalk). I'm fairly certain it isn't actually an error with the coding, as these were some of the initial functions I wrote into the code, and they have always worked.
The question
What could be some causes of random erros (that are not detected by the program/IDE) such as what I've mentioned above in coding (whether local to C++ or Allegro)?