to build scilab on Windows (temp.)
[scilab.git] / scilab / modules / core / src / c / callFunctionFromGateway.c
1 /*-----------------------------------------------------------------------------------*/
2 /* INRIA 2007 */
3 /* Allan CORNET */
4 /*-----------------------------------------------------------------------------------*/
5 #include <string.h>
6 #ifdef _MSC_VER
7 #include <Windows.h>
8 #include "ExceptionMessage.h"
9 #endif
10 #include "callFunctionFromGateway.h"
11 #include "stack-c.h"
12 /*-----------------------------------------------------------------------------------*/
13 void callFunctionFromGateway(gw_generic_table *Tab)
14 {
15 #ifdef _MSC_VER
16 #ifndef _DEBUG
17         _try
18         {
19                 if (*(Tab[Fin-1].f) != NULL) (*(Tab[Fin-1].f)) (Tab[Fin-1].name,(unsigned long)strlen(Tab[Fin-1].name));
20         }
21         _except (EXCEPTION_EXECUTE_HANDLER)
22         {       
23                 ExceptionMessage(GetExceptionCode(),Tab[Fin-1].name);
24         }
25 #else
26         if (*(Tab[Fin-1].f) != NULL) (*(Tab[Fin-1].f)) (Tab[Fin-1].name,(unsigned long)strlen(Tab[Fin-1].name));
27 #endif
28 #else
29         if (*(Tab[Fin-1].f) != NULL) (*(Tab[Fin-1].f)) (Tab[Fin-1].name,(unsigned long)strlen(Tab[Fin-1].name));
30 #endif
31 }
32 /*-----------------------------------------------------------------------------------*/