VOID Func2() { printf("[%s] 0x%08p \n", __FUNCTION__, Func2); Func3(); }
void Proc6(Enumeration EnumParIn, Enumeration *EnumParOut) { *EnumParOut = EnumParIn; if (! Func3(EnumParIn) ) *EnumParOut = Ident4; switch (EnumParIn) { case Ident1: *EnumParOut = Ident1; break; case Ident2: if (IntGlob > 100) *EnumParOut = Ident1; else *EnumParOut = Ident4; break; case Ident3: *EnumParOut = Ident2; break; case Ident4: break; case Ident5: *EnumParOut = Ident3; } }
void Run() { mTestState = 0; switch( mTestNum ) { case 1: Func1(); // Async Event give it 100ms to be recieved. usleep( 100000 ); if ( mTestState != 1 ) TestFailed( "Event not recieved" ); else if ( sEventCount != 0 ) TestFailed( "Event count != 0 (%d)", sEventCount ); else TestPassed(); break; case 2: Func2( 1, 2 ); // Sync Event no need to sleep. if ( mTestState != 1 ) TestFailed( "Event not recieved" ); else if ( sEventCount != 0 ) TestFailed( "Event count != 0 (%d)", sEventCount ); else TestPassed(); break; case 3: int res = Func3( 3 ); // Sync Event no need to sleep. if ( mTestState != 1 ) TestFailed( "Event not recieved" ); else if ( res != 1000 ) TestFailed( "Result not valid" ); else if ( sEventCount != 0 ) TestFailed( "Event count != 0 (%d)", sEventCount ); else TestPassed(); break; } }
void Func2(int a, char *b) SDSV SWP_IS(a, b) { if (Func3(3,1) != 5) ERR("ooops retval 1!"); if (Func3(6,2) != 9) ERR("ooops retval 2!"); if (Func3(12,3) != 12) ERR("ooops retval 3!"); } SDFV
void Func2() { Func3(); }
static void GetNull(Func3& dst) { dst = Func3(0, 0); }