bks@alfa.berkeley.edu (Brad Sherman) (01/20/90)
With respect to writing *portable* C: Has anyone come up with what he/she thinks is a good way to code signal handling. Signal names and numbers are not standardized. We may wish to enable/ignore them at different points in a program (without confusing the user of course). Not all types of signals exist on all systems. What I am after here is a way to localize (encapsulate?) signal handling so that accommodating a new C environment is simplified. Probably a tougher issue is dealing with questions of multiple signals arriving in quick succession, but I welcome input on this as well. Although I think that this is worthy of an open discussion, if I receive e-mail I will summarize. --- Brad Sherman (bks@alfa.berkeley.edu) Never attribute to stupidity that which can be explained by greed.
karl@haddock.ima.isc.com (Karl Heuer) (01/20/90)
In article <1990Jan19.193917.23671@agate.berkeley.edu> bks@alfa.berkeley.edu (Brad Sherman) writes: >Has anyone come up with what he/she thinks is a good way to code signal >handling. Signal names and numbers are not standardized. Sure they are. X3J11 standardized 6 of them, and 1003.1 another 13. >Not all types of signals exist on all systems. My recommendation is to use POSIX as a base, and on non-Standard systems, attempt to emulate the POSIX behavior (by returning an error code for inappropriate signal values, for example). Karl W. Z. Heuer (karl@haddock.isc.com or ima!haddock!karl), The Walking Lint