Other Tasks; File Descriptors; Signal Handlers - HP A4500A - VMEbus Single Board Computer 744 Motherboard Programmer's Manual

Acse/presentation and rose interface programmer's guide
Hide thumbs Also See for A4500A - VMEbus Single Board Computer 744 Motherboard:
Table of Contents

Advertisement

Programming Guide

6. Other Tasks

6. Other Tasks
Other items to consider in developing A/P applications include:

• File descriptors

• Signal handling
• Error checking
File Descriptors
Communication endpoints for ACSE/Presentation applications are
HP-UX file descriptors. Because of unpredictable results, HP
recommends you do not use HP-UX file system calls such as exec(2),
dup(2), read(2), write(2), ioctl(2), or select(2) with HP OTS/9000 A
CSE/Presentation file descriptors. Note that fork(2) can be used, but do
not use fork(2) with exec(2).
A communication endpoint is returned when the ACSE/Presentation call
ap_open() is invoked.
Note that the user may need to increase the open file limit for the
application process to support a large number of connections. Refer to
the getrlimit() and setrlimit() system call manpages for more information
on changing file limits.

Signal Handlers

ACSE/Presentation calls interrupted by the arrival of a signal will not be
restarted by the library. You are responsible for managing signals and
providing recovery routines for the duration of any ACSE/Presentation
calls. Signals are interrupts such as when you enter ˆC on a terminal to
exit from a program.
If an interrupt occurs while executing A/P functions, the operating
system class error EINTR is returned. When detected, you must
re-invoke the A/P function. If EINTR is detected while executing
ap_snd() or ap_rcv(), the call must be invoked again as described in how
to handle AP_AGAIN in the ap_snd() and ap_rcv() manpages (for both
synchronous and asynchronous processing). The A/P library continues
the call from where it left off.
62
Chapter 4

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents