=================================================================== RCS file: /home/cvs/OpenXM/src/kan96xx/plugin/oxmisc.c,v retrieving revision 1.10 retrieving revision 1.12 diff -u -p -r1.10 -r1.12 --- OpenXM/src/kan96xx/plugin/oxmisc.c 2001/08/10 13:48:39 1.10 +++ OpenXM/src/kan96xx/plugin/oxmisc.c 2002/02/24 10:27:20 1.12 @@ -1,4 +1,4 @@ -/* $OpenXM: OpenXM/src/kan96xx/plugin/oxmisc.c,v 1.9 2001/05/04 01:06:30 takayama Exp $ */ +/* $OpenXM: OpenXM/src/kan96xx/plugin/oxmisc.c,v 1.11 2001/12/28 08:18:22 takayama Exp $ */ #include #include #include @@ -883,10 +883,18 @@ char *oxGenPass(void) { static void cancelConnection() { +#if defined(__CYGWIN__) + extern sigjmp_buf MyEnv_oxmisc; +#else extern jmp_buf MyEnv_oxmisc; +#endif signal(SIGALRM,SIG_IGN); fprintf(stderr,"Time out in TCP/IP connection.\n"); +#if defined(__CYGWIN__) + siglongjmp(MyEnv_oxmisc,1); +#else longjmp(MyEnv_oxmisc,1); +#endif } oxclientp oxCreateClient2(int fdstream,int portStream, @@ -900,15 +908,23 @@ oxclientp oxCreateClient2(int fdstream,int portStream, char *s; oxclientp client; - extern jmp_buf MyEnv_oxmisc ; +#if defined(__CYGWIN__) + extern sigjmp_buf MyEnv_oxmisc; +#else + extern jmp_buf MyEnv_oxmisc; +#endif int controlByteOrder, engineByteOrder; v = !Quiet; +#if defined(__CYGWIN__) + if (sigsetjmp(MyEnv_oxmisc,1)) { +#else if (setjmp(MyEnv_oxmisc)) { +#endif return(NULL); }else{ } - alarm((unsigned int) 10); /* setup timeout. */ + alarm((unsigned int) 20); /* setup timeout. */ signal(SIGALRM,cancelConnection); switch(ipmask) {