callinterf.c File Reference

#include <setjmp.h>
#include <stdio.h>
#include <ctype.h>
#include <signal.h>
#include "machine.h"
#include "sciprint.h"
#include "Scierror.h"
#include "csignal.h"
#include "addinter.h"
#include "Os_specific.h"
#include "callinterf.h"

Include dependency graph for callinterf.c:

Go to the source code of this file.

Data Structures

struct  OpTab

Functions

int C2F (error)
void C2F() NoPvm (void)
void C2F() Nogw_scicos (void)
void C2F() Nogw_cscicos (void)
void C2F() Nogw_slicot (void)
int C2F() callinterf (int *k, int *iflagint)
static void sci_sigint_addinter (int n)
int Blas_contents __PARAMS ((int))
int ForceLink (void)
void errjump (int n)

Variables

static jmp_buf jmp_env
static int sig_ok = 0


Function Documentation

int Blas_contents __PARAMS ( (int  ) 

int C2F ( error   ) 

Definition at line 21 of file callinterf.c.

References C2F, error, and sciprint().

00040 {
00041   sciprint("TclSci interface not loaded \n");
00042   C2F(error)(&c_local_interf);
00043   return;
00044 }

Here is the call graph for this function:

int C2F() callinterf ( int k,
int iflagint 
)

Definition at line 91 of file callinterf.c.

References C2F, controlC_handler(), count, DynInterfStart, Interfaces, jmp_env, sci_sigint_addinter(), sig_ok, and userlk().

Referenced by scibuiltin(), scifunction(), scirun(), and syncexec().

00092 {
00093   int returned_from_longjump ;
00094   static int count = 0;
00095   if ( count == 0) 
00096     {
00097       if (sig_ok) signal(SIGINT,sci_sigint_addinter);
00098       if (( returned_from_longjump = setjmp(jmp_env)) != 0 )
00099         {
00100           if (sig_ok) signal(SIGINT, controlC_handler);
00101           Scierror(999,"SIGSTP: aborting current computation\r\n");
00102           count = 0;
00103           return 0;
00104         }
00105     }
00106   count++;
00107   if (*k > DynInterfStart) 
00108     C2F(userlk)(k);
00109   else
00110     (*(Interfaces[*k-1].fonc))();
00111   count--;
00112   if (count == 0) { 
00113     if (sig_ok) signal(SIGINT, controlC_handler);
00114   }
00115   return 0;
00116 }

Here is the call graph for this function:

Here is the caller graph for this function:

void errjump ( int  n  ) 

Definition at line 163 of file callinterf.c.

References jmp_env.

Referenced by mexerrmsgtxt(), mexErrMsgTxt(), mexEvalString(), and sci_sigint_addinter().

00164 {
00165   longjmp(jmp_env,-1); 
00166 }

Here is the caller graph for this function:

int ForceLink ( void   ) 

Definition at line 143 of file callinterf.c.

00144 {
00145         /*  
00146                 commented for test purpose by Sylvestre (no sure it is mandatory
00147 Blas_contents(0);
00148   Lapack_contents(0);
00149   Calelm_contents(0);
00150   Sun_contents(0);
00151   System2_contents(0);
00152   System_contents(0);
00153   Intersci_contents(0);
00154   Sparse_contents(0);*/
00155   return 0;
00156 }

void C2F() Nogw_cscicos ( void   ) 

Definition at line 60 of file callinterf.c.

References C2F, error, and sciprint().

00061 {
00062         sciprint("scicos interfaces not loaded \n");
00063         C2F(error)(&c_local_interf);
00064         return;
00065 }

Here is the call graph for this function:

void C2F() Nogw_scicos ( void   ) 

Definition at line 53 of file callinterf.c.

References C2F, error, and sciprint().

00054 {
00055         sciprint("scicos interfaces not loaded \n");
00056         C2F(error)(&c_local_interf);
00057         return;
00058 }

Here is the call graph for this function:

void C2F() Nogw_slicot ( void   ) 

Definition at line 68 of file callinterf.c.

References C2F, error, and sciprint().

00069 {
00070         sciprint("Slicot interfaces not loaded \n");
00071         C2F(error)(&c_local_interf);
00072         return;
00073 }

Here is the call graph for this function:

void C2F() NoPvm ( void   ) 

Definition at line 46 of file callinterf.c.

References C2F, error, and sciprint().

00047 {
00048   sciprint("pvm interface not loaded \n");
00049   C2F(error)(&c_local_interf);
00050   return;
00051 }

Here is the call graph for this function:

static void sci_sigint_addinter ( int  n  )  [static]

Definition at line 118 of file callinterf.c.

References errjump(), and sciprint().

Referenced by callinterf().

00119 {
00120   int c;
00121   sciprint("Trying to stop scilab in the middle of an interface\n");
00122   sciprint("Do you really want to abort computation (y n  ?) ");
00123   c = getchar();
00124   if ( c == 'y' ) errjump(n);
00125 }

Here is the call graph for this function:

Here is the caller graph for this function:


Variable Documentation

jmp_buf jmp_env [static]

Definition at line 19 of file callinterf.c.

Referenced by callinterf(), and errjump().

int sig_ok = 0 [static]

Definition at line 89 of file callinterf.c.

Referenced by callinterf().


Generated on Sun Mar 4 15:14:38 2007 for Scilab [trunk] by  doxygen 1.5.1