pointer trouble


2005-10-07 11:45:56 PM
cppbuilder12
First off, I appreciate any responses immensely.
Does anyone know why this code works in visual c++ but throws an
exception in c++ builder 6:
void inttest(int *x);
void __fastcall TForm1::Timer1Timer(TObject *Sender)
{
int x;
x = 1;
inttest(&x);
}
void inttest(int *x)
{
*x = 2;
return;
}