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:

mbstate_t - incompatible data type (CrCh116)

I18N Impacts

Problem description

The mbstate_t data type definition on Tru64 UNIX and HP-UX is different.

The mbstate_t structure is an opaque data structure. On HP-UX, mbstate_t is defined only if _XOPEN_SOURCE is defined to be equal to 500. If your code accesses any member of this structure, it is not portable, and cannot be ported to HP-UX. This structure is mostly used by the identified restartable versions of I18N Application Programming Interfaces(APIs).

Identifiers

C/C++ Functionsmbrlen C/C++ Functionsmbsinit C/C++ Misc. Identifiersmbstate_t C/C++ Functionswcsrtombs  
C/C++ Functionsmbrtowc C/C++ Functionsmbsrtowcs C/C++ Functionswcrtomb    

See also

Solution description

Review and modify your code.

The APIs that use mbstate_t are functionally equivalent to the nonrestartable versions in locales that do not use shift-state encoding. The only advantage to using some of these restartable APIs is that additional error codes might be returned in some cases. Neither Tru64 UNIX nor HP-UX provide any locales that use shift-state encoding.

If your code uses the mbstate_t structure, you must do the following:

  • Define _XOPEN_SOURCE=500.
  • Initialize the structure to zero before porting to HP-UX.

New behavior

See also


Problem summary

classifications source types OS release severity type
I18N 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.