Jump to content
HP.com Home Products and Services Support and Drivers Solutions How to Buy
» Contact HP
HP.com home

Transition Impacts

Tru64 UNIX Software Transition Kit
» 

DSPP Home

» HP STK home
Tru64 UNIX STK
» Home
» Overview
» Tools
» Documentation
» Transition impacts
» Identifier types
» Impact list
» Porting to HP-UX
» FAQ
» Glossary
» Help
» Send us feedback
Site maps
» Tru64 UNIX STK
» DSPP
Content starts here

critical impact:

sigaction, sigset_t - incompatible data types (CrCh112)

SIG Impacts

Problem description

The sigaction structure and sigset_t type on Tru64 UNIX are incompatible with the ones on HP-UX. Applications that use them in nonstandard ways might need to make code changes.

The sa_mask field of the sigaction structure is a sigset_t. The standard way to clear a signal set is with sigemptyset. On Tru64 UNIX, some programmers take a shortcut and set it to 0 (zero) directly. That is not portable, and will not compile on HP-UX because HP-UX implements sigset_t differently.

The Tru64 UNIX sigaction structure also has a nonstandard sa_signo field that does not exist on HP-UX. Tru64 UNIX applications do not need to set it because the kernel always overwrites whatever they set it to.

Identifiers

C/C++ Structuressigaction C/C++ Misc. Identifierssigset_t      

Old behavior

struct sigaction sa;
sa.sa_handler = handler;
sa.sa_mask  = 0;
sa.sa_flags = 0;
sa.sa_signo = SIGINT;

See also

Solution description

Review the applicable manpages and code to determine if you are using these data types in nonstandard ways.

New behavior

struct sigaction sa;
sa.sa_handler = handler;
sigemptyset(&sa.sa_mask);
sa.sa_flags = 0;

See also


Problem summary

classifications source types OS release severity type
SIG C, C++ any HP-UX 11i version critical changed
Printable version
Privacy statement Using this site means you accept its terms Feedback to DSPP
© 2007 Hewlett-Packard Development Company, L.P.