[Kevin Dempsey: Problems w/Informix ESQL and UNIX sleep() function.]
Posted in 1992
Can we help this fellow with his problem? Since he is obviously not a subscriber
perhaps responses should go to him.
Thanks.
Date: Mon, 13 Jan 92 15:28:10 GMT
From: Kevin Dempsey <dempsey@worms-emh2.army.mil>
Subject: Problems w/Informix ESQL and UNIX sleep() function.
13 January 1992
NOTE TO: UNIXTIE
From: Kevin Dempsey, Worms Germany
Problem Descriptions:
1. An ESQL-compiled program (Informix Ver 4.0) does not allow
use of some UNIX system and subroutine calls (Unix System V,
Release 3.2.2.19) that utilize interrupts.
a. Attempts to use the UNIX subroutine call 'sleep(sec)'
results in a process terminating error which gives the message:
"Illegal instruction - core dumped". The ESQL program compiles
properly with the 'sleep(sec)' function included but the program
blows up when the interrupt-driven 'sleep(sec)' process is
activated. Also, the program does not compile when the system
call 'alarm(sec)' is included. An error message: "illegal
function" is shown upon compilation attempts. These errors do
not occur in our other C programs compiled with 'cc' (not with
'esql') that utilize 'sleep(sec)' and 'alarm(sec)'. The ESQL
compilation command being used is:
$ esql -o executable_name program_name.ec -lcurses -ltermlib
b. Because this application program is used as a non-stop
continuously running process, we need to have a way to put this
process to sleep occasionally in order to reduce processor load.
The only function we have found to work with ESQL is a Curses
function called 'delay_output(msec)'. It only works because the
'delay_output(msec)' function uses padding characters rather than
processor interrupts. Obviously, this will not help us for any
programs not using Curses for screen displays. We should be able
to use all standard UNIX system and subroutine calls in a C with
embedded-SQL program.
2. The Curses function call 'napms(ms)' does not work on the
version of curses on the AT&T 3b2 (Ver 3.2.2.19). The program
compiles and runs but the function call is simply ignored.
3. Would appreciate any help you could provide. Until we can
get our System maintenance started, AT&T shows only a little
interest but very little!