**************************************************** ECO SUMMARY INFORMATION **************************************************** Release Date: 09-OCT-2003 Kit Name: VMS73_ACRTL-V0600 DEC-AXPVMS-VMS73_ACRTL-V0600--4.PCSI Kit Applies To: OpenVMS ALPHA V7.3 Approximate Uncompressed Kit Size: 17360 blocks Installation Rating: INSTALL_3 Reboot Required: Yes - Rolling Reboot Superseded Kits: VMS73_ACRTL-V0500 Mandatory Kit Dependencies: VMS73_PCSI-V0100 VMS73_UPDATE-V0200 Optional Kit Dependencies: None VMS73_ACRTL-V0600.PCSI-DCX_AXPEXE Checksum: 2139335988 ***************************************************** HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes October, 2003 (c) Copyright 2003 Hewlett-Packard Development Company, L.P. UNIX is a registered trademark of The Open Group. X/Open is a registered trademark of X/Open Company Ltd. in the UK and other countries. The information contained herein is subject to change without notice. The only warranties for HP products and services are set forth in the express warranty statements accompanying such products and services. Nothing herein should be construed as constituting an additional warranty. HP shall not be liable for technical or editorial errors or omissions contained herein. Proprietary computer software. Valid license from HP required for possession, use or copying. Consistent with FAR 12.211 and 12.212, Commercial Computer Software, Computer Software Documentation, and Technical Data for Commercial Items are licensed to the U.S. Government under vendor's standard commercial license. HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 2 CONTENTS 1 Introduction . . . . . . . . . . . . . . . . . . . . 3 2 Kit Name . . . . . . . . . . . . . . . . . . . . . . 3 3 Kits superseded by this kit . . . . . . . . . . . . 3 4 Kit Dependencies . . . . . . . . . . . . . . . . . . 3 4.1 Required remedial kits before installation . . . . 3 4.2 Required remedial kits . . . . . . . . . . . . . . 3 5 Kit Description . . . . . . . . . . . . . . . . . . 3 5.1 Version(s) of OpenVMS to which this kit may be applied: . . . . . . . . . . . . . . . . . . . . . 3 5.2 Files patched or replaced: . . . . . . . . . . . . 3 6 Problems addressed in kit VMS73_ACRTL-V0600 . . . . 4 7 Problems addressed in kit VMS73_ACRTL-V0500 . . . 13 8 Problems addressed in kit VMS73_ACRTL-V0400 . . . 14 9 Problems addressed in kit VMS73_ACRTL-V0300 . . . 14 10 New Features in kit VMS73_ACRTL-V0300 . . . . . . 16 10.1 64-bit pointer support for some socket functions: 16 10.2 New feature logical DECC$ALLOW_REMOVE_OPEN_FILES added to control the behavior of remove() on open files. . . . . . . . . . . . . . . . . . . . . 17 10.3 New socket function poll(): . . . . . . . . . . 17 10.4 New function pread(): . . . . . . . . . . . . . 20 10.5 New function pwrite(): . . . . . . . . . . . . . 21 10.6 New functions readv(), _readv64(): . . . . . . . 22 10.7 New function variant __writev64(): . . . . . . . 24 10.8 New function decc$set_child_default_dir(): . . . 24 11 Problems addressed in kit VMS73_ACRTL-V0200 . . . 25 12 C RTL Feature Switches Described in VMS73_ACRTL-V0200 . . . . . . . . . . . . . . . . 32 12.1 List of Features . . . . . . . . . . . . . . . . 33 12.1.1 Reference List of Features . . . . . . . . . . . 34 12.2 Enhanced Support for UNIX Style File Names . . . 44 12.3 POSIX Root Support . . . . . . . . . . . . . . . 45 12.4 32-Bit Group Identifiers . . . . . . . . . . . . 46 13 Kit Installation Rating . . . . . . . . . . . . . 47 14 Installation Instructions . . . . . . . . . . . . 47 14.1 Special Installation Instructions: . . . . . . . 47 14.1.1 %INSTALL-E-NODELSHRADR Error Message . . . . . . 47 14.1.2 Scripting of Answers to Installation Questions . 48 HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 3 Introduction This document contains the release notes for the HP C Run Time Library ECO patch kit on OpenVMS Alpha V7.3. Kit Name VMS73_ACRTL-V0600 Kits superseded by this kit VMS73_ACRTL-V0500 VMS73_ACRTL-V0400 VMS73_ACRTL-V0300 VMS73_ACRTL-V0200 Kit Dependencies Required remedial kits before installation The following remedial kit(s) must be installed BEFORE installation of this, or any required kit: VMS73_UPDATE-V0100 VMS73_PCSI-V0100 Required remedial kits In order to receive all the corrections listed in this kit, the following remedial kits should also be installed: None. Kit Description Version(s) of OpenVMS to which this kit may be applied: OpenVMS Alpha V7.3 Files patched or replaced: o [SYSLIB]DECC$SHR.EXE (new image) o [SYSLIB]CRTL.OBJ (new file - used to update STARLET.OBJ) HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 4 o [SYSLIB]CRTLMSGDEF.OBJ (new file - used to update STARLET.OBJ) Problems addressed in kit VMS73_ACRTL-V0600 Unless otherwise stated, all problems listed are fixed. o VMS73_ACRTL-V0500 ECO kit incompatible with VMS 7.3-2 Programs linked against the VMS73_ACRTL-V0500 ECO kit will be incompatible with OpenVMS Version 7.3-2 and will not run properly on OpenVMS 7.3-2. HP removed the VMS73_ACRTL-V0500 ECO kit from distribution and recommends use of this VMS73_ACRTL-V0600 ECO kit instead. If you have already installed the VMS73_ACRTL-V0500 ECO kit, HP recommends that you uninstall that kit before installing the VMS73_ACRTL-V0600 ECO kit: o If you installed the VMS73_ACRTL-V0500 ECO kit with the /SAVE_RECOVERY_DATA qualifier, remove the kit with the PRODUCT UNDO PATCH command. o If you installed the VMS73_ACRTL-V0500 kit without using the /SAVE_RECOVERY_DATA qualifier, restore your pre-kit environment from BACKUP. After uninstalling VMS73_ACRTL-V0500, install the VMS73_ACRTL-V0600 ECO kit. Programs that were linked against the VMS73_ACRTL-V0500 ECO kit need to be relinked for use with the VMS73_ACRTL-V0600 ECO kit or subsequent version of OpenVMS. o The access() function is enhanced to also check for OpenVMS ACLs. In previous versions of the C RTL, the access() function only checked UIC protection and not OpenVMS Access Control Lists (ACLs). A new feature logical, DECC$ACL_ACCESS_CHECK, has been added that lifts this restriction. With DECC$ACL_ACCESS_CHECK enabled, the access() function now checks both UIC protection and ACLs. o The snprintf() and vsnprintf() functions are added to the C RTL. #include int snprintf (char *str, size_t n, const char *format_spec, ...); int vsnprintf (char *str, size_t n, const char *format, va_list ap); The snprintf() function prints formatted output based on an argument list, and is identical to the sprintf() function with the addition of the n argument, which specifies the size of the HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 5 buffer referred to by str. On successful completion, snprintf returns the number of bytes (excluding the terminating null byte) that would be written to str if n is sufficiently large. If n is 0, nothing is written, the number of bytes (excluding the terminating null) that would be written if n were sufficiently large are returned, and str might be a NULL pointer. Otherwise, output bytes beyond the n - 1st are discarded instead of being written to the array, and a null byte is written at the end of the bytes actually written into the array. If an output error is encountered, a negative value is returned. The vsnprintf() function is the same as the snprintf() function, but instead of being called with a variable number of arguments, it is called with an argument list that has been initialized by va_start (and possibly with subsequent va_arg calls). This function does not invoke the va_end macro. Because the function invokes the va_arg macro, the value of ap after the return is unspecified. Applications using vsnprintf() should call va_end(ap) afterwards to clean up. o The getpwnam_r() function is added to the C RTL. #include int getpwnam_r (const char *name, struct passwd *pwd, char *buffer, size_t bufsize, struct passwd **result); (ISO POSIX-1) int getpwnam_r (const char *name, struct passwd *pwd, char *buffer, size_t bufsize, struct passwd **result, ...); (HP C extension) The getpwnam_r() function is the reentrant version of getpwnam(). The getpwnam_r() function updates the passwd structure pointed to by pwd and stores a pointer to that structure at the location pointed to by result. The structure will contain an entry from the user database that matches the specified name. Storage referenced by the structure is allocated from the memory provided with the buffer argument, which is bufsize characters in length. The maximum size needed for this buffer can be determined with the _SC_GETPW_R_SIZE_MAX parameter of the sysconf() function. On error or if the requested entry is not found, a NULL pointer is returned at the location pointed to by result. In the HP C extension format, getpwnam_r takes an optional argument that can be either 1 or 0. If you specify 1, the directory specification is returned in OpenVMS format. If you specify 0, the directory specification (pathname) is returned HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 6 in UNIX style format. If you omit this argument, the function returns the directory specification according to your current command-language interpreter. o The getpwuid_r() function is added to the C RTL. #include int getpwuid_r (uid_t uid, struct passwd *pwd, char *buffer, size_t bufsize, struct passwd **result); (ISO POSIX-1) int getpwuid_r (uid_t uid, struct passwd *pwd, char *buffer, size_t bufsize, struct passwd **result, ...); (HP C extension) The getpwuid_r() function is the reentrant version of getpwuid). The getpwuid_r() function updates the passwd structure pointed to by pwd and stores a pointer to that structure at the location pointed to by result. The structure will contain an entry from the user database that matches the specified uid. Storage referenced by the structure is allocated from the memory provided with the buffer argument, which is bufsize characters in length. The maximum size needed for this buffer can be determined with the _SC_GETPW_R_SIZE_MAX parameter of the sysconf() function. On error or if the requested entry is not found, a NULL pointer is returned at the location pointed to by result. In the HP C extension format, getpwuid_r takes an optional argument that can be either 1 or 0. If you specify 1, the directory specification is returned in OpenVMS format. If you specify 0, the directory specification (pathname) is returned in UNIX style format. If you omit this argument, the function returns the directory specification according to your current command-language interpreter. o 64-bit support is added to the getpwnam(), getpwuid(), and getpwent() functions and their reentrant variants. The following 64-bit entry points have been added for the getpw family of functions: __64_getpwnam _getpwnam_r64 __64_getpwuid _getpwuid_r64 __64_getpwent o The header file is now in DECC$RTLDEF.TLB. The header file was inadvertently omitted from DECC$RTLDEF.TLB in a previous C RTL ECO kit. This is now fixed. The header file has been restored. o IPv6 programming note The most current TCP/IP related header files ship with TCPIP V5.4. When that version of TCP/IP Services is installed, the files are located in TCPIP$EXAMPLES. The one exception is HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 7 , which in the current DECC$RTLDEF.TLB shipped with OpenVMS V7.3-2 is conceptually, but not textually, the same as the TCP/IP Services V5.4 variant in TCPIP$EXAMPLES. o The pread() and pwrite() functions now fail on sockets, as they should. The X/Open specification states that an attempt to perform a pread() or pwrite() on a file that is not seekable should result in an error. But previously, the C RTL implementation of the pread() and pwrite() functions did not return an error for a file descriptor (FD) associated with an unseekable file. Instead, the offset parameter was ignored and the operation treated like a normal read/write, so the pread() or pwrite() call would succeed. The pread() and pwrite() functions have been modified so that when the file is not a seekable file, the error code ESPIPE is returned to indicate that the FD is associated with a pipe or FIFO, and is therefore not seekable. o Mixed (rooted and nonrooted) logical name search lists now work. Using mixed (rooted and nonrooted) logical name search lists works on OpenVMS Version 7.1-2, but might generate an error for OpenVMS Version 7.2-2 and higher. This problem has been fixed with the addition of a new feature logical. The DECC$NO_ROOTED_SEARCH_LISTS feature logical controls how the decc$to_vms() function resolves search-list logicals. When the decc$to_vms() function evaluates a UNIX style path string, if it determines the first element to be a logical name, then: - For rooted logicals or devices, it appends ":[000000]" to the logical name. For example, if log1 is a rooted logical ($DEFINE LOG1 [DIR_NAME.]), then /log1/filename.ext translates to LOG1:[000000]FILENAME.EXT. - For nonrooted logicals, it appends just a colon (:) to the logical name. For example, if log2 is a nonrooted logical ($ DEFINE LOG2 [DIR_NAME]), then /log2/filename.ext translates to LOG2:FILENAME.EXT. - If the first element is a search-list logical, the translation proceeds by evaluating the first element in the search list, and translating the path as previously described. The preceding three cases lead to predictable, expected HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 8 results. In the case where the first element is a search list that consists of a mixture of rooted and nonrooted logicals, translating paths as described above can lead to different behavior from that of older versions of OpenVMS (before OpenVMS Version 7.3-1): - Before OpenVMS Version 7.3-1, regardless of the contents of the logical, the decc$to_vms() function appended only a colon (:). For search lists that consisted of a mixture of rooted and non-rooted logicals, this resulted in certain expected behaviors. - For OpenVMS Version 7.3-1 and later, if the first element of the mixed search list is a rooted logical, then decc$to_vms() appends ":[000000]" to the logical name, resulting in different behavior from that of OpenVMS releases prior to Version 7.3-1. DECC$NO_ROOTED_SEARCH_LISTS controls how the decc$to_vms() function resolves search-list logicals and provides a means to restore the OpenVMS behavior prior to Version 7.3-1. With DECC$NO_ROOTED_SEARCH_LISTS enabled: - If a logical is detected in a file specification, and it is a search list, then a colon (:) is appended when forming the OpenVMS file specification. - If it is not a search list, the behavior is the same as with DECC$NO_ROOTED_SEARCH_LISTS disabled. Enabling this feature logical provides the pre-Version 7.3-1 behavior for search list logicals. With DECC$NO_ROOTED_SEARCH_LISTS disabled: - If a logical is detected in a file specification, and it is a rooted logical (or a search list whose first element is a rooted logical), then ":[000000]" is appended when forming the OpenVMS file specification. - If it is a nonrooted logical (or a search list whose first element is a non-rooted logical), then just a colon (:) is appended. Disabling this feature logical provides the behavior for OpenVMS Version 7.3-1 and later. o Program deadlock problem is fixed. A possible deadlock situation existed when one process would receive a signal from another process, resulting in unexpected program hangs. This problem was reported with a particular Oracle application, HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 9 but could be seen by other programs as well. This problem is fixed. o The inet_ntop() function is now defined as returning "const char *". Previous versions of the C RTL defined the inet_ntop() function as returning type "char *". To conform to industry standards, the declaration of inet_ntop() is now changed to return "const char *". o The inet_ntop() and inet_pton() functions now handle 64-bit pointers. The Header file exposed inet_ntop() and inet_pton() as functions that accepted 64-bit pointers, but the corresponding implementations did not actually handle 64-bit pointers and would ACCVIO if called with true 64-bit pointers. This has been fixed. Both functions now correctly handle 64-bit pointers. o The FILE_TYPE macro is removed from the header file. The header file contained the nonstandard macro FILE_TYPE. This macro has been removed from the header file to prevent name space pollution. o The tm_t structure is removed from the header file. The header file included a definition of nonstandard structure tm_t. This structure definition has been removed from the header file to prevent name space pollution. o Prototype conditionalization problems in are fixed. Previously, when the header file was compiled in any standard mode (/stand=ansi or stand=c99), the prototype for several functions (utimes, clock_gettime, clock_settime, clock_getres, and nanosleep) were exposed, resulting in PROTOSCOPE compiler informational messages. The prototype definitions of these functions are now within the following conditionalization: if defined _XOPEN_SOURCE_EXTENDED || (!defined _ANSI_C_SOURCE && !defined _DECC_V4_SOURCE) o Workaround is provided for potential problem with redefinition of structures when including or . A potential problem with redefinition of structures can occur in programs that directly or indirectly include either the or header file. In previous OpenVMS versions, the marker symbol _TIMESPEC_T_ was used to indicate HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 10 that the timespec structure and timespec_t typedef had already been defined. As of this ECO kit, if the or header file is included in a program before a definition of the timespec structure that only checks for and sets the _TIMESPEC_T_ marker symbol, the compiler will issue a REDEFSTRUCT error. To correct this problem, modify the program to use the new marker symbols __TIMESPEC and __TIMESPEC_T to indicate a prior definition of the timespec structure and timespec_t typedef, respectively, in addition to the prior use of the _TIMESPEC_T_ marker symbol. Details: Previously, the header file included the following definitions: #ifndef _TIMESPEC_T_ # define _TIMESPEC_T_ typedef struct timespec { unsigned long tv_sec; /* seconds */ long tv_nsec; /* nanoseconds */ } timespec_t; #endif In this definition, the marker symbol _TIMESPEC_T_ is used to avoid redefinition of the timespec structure and the timespec_t typedef. Now, in this ECO kit, the header file is modified to include this definition: #ifndef _TIMESPEC_T_ # define _TIMESPEC_T_ # ifndef __TIMESPEC # define __TIMESPEC struct timespec { unsigned long tv_sec; /* seconds */ long tv_nsec; /* nanoseconds */ }; # endif # ifndef __TIMESPEC_T # define __TIMESPEC_T typedef struct timespec timespec_t; # endif #endif This modification: - Separates the structure definition from the typedef definition. HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 11 - Preserves the _TIMESPEC_T_ marker symbol, which continues to indicate that both the timespec_t typedef and the timespec structure have been defined. - Adds two new marker symbols, __TIMESPEC_T and __TIMESPEC, to indicate the definition of the timespec_t typedef and timespec structure, respectively. In addition, the standard header files and are modified to include the following structure definition: # if (!defined __TIMESPEC && !defined _TIMESPEC_T_) # define __TIMESPEC struct timespec { unsigned long tv_sec; /* seconds */ long tv_nsec; /* nanoseconds */ }; # endif o exec() no longer gets 0x35DF94 error. C programs that make use of the vfork()/exec*() calls might see unexpected %X35DF94 errors returned from the exec() call. This problem is fixed. o Compiler errors no longer experienced after upgrading to OpenVMS Version 7.3-1. The header file was modified to change the declaration of internal function prototype LIB$GET_CURRENT_INVO_CONTEXT such that it was different from the declaration of the same function in the header files and . This difference would result in %CXX-E-OVLDBASEDPTRTYP errors when compiling any module that directly or indirectly included and either or . This problem has been fixed. The declaration of LIB$GET_CURRENT_INVO_CONTEXT is now consistent across all three header files. o Missing entry points for BSD 4.4 functions fixed. Previously, the getaddrinfo(), freeaddrinfo(), getnameinfo(), and gai_strerror() functions were erroneously getting prefixed with "__bsd44_" when they should not have been, resulting in a link-time undefined-symbol error such as the following: %LINK-W-USEUNDEF, undefined symbol __BSD44_GETNAMEINFO referenced This is fixed in the header file shipped with this ECO kit, so the above functions are no longer prefixed with "__bsd_44_". HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 12 o Correct IPv6 symbol names are now in UCX$IPC_XHR.EXE Nine IPv6 related functions (inet6_xxxx) that were added to the C RTL for OpenVMS Version 7.3 had names that did not match the corresponding function names in the underlying TCP/IP layer. User applications that used these functions in the C RTL got an error indicating that the functions were not implemented. This is fixed. o Problem with translation of certain UNIX names is fixed. Previously, UNIX file names like /logname were not translated successfully when logname resolved to a file like sys$login:login.com. This is now fixed. o New feature logical lets rename() handle logical names correctly. In some recent versions of the C RTL, the rename() function did not allow conversion to a directory specification in the case where, for the second argument, an ambiguous file specification is passed as a logical name, the ambiguity being whether or not the logical represented a UNIX or an OpenVMS pathname. This was a change in behavior from yet earlier OpenVMS versions, which did handle these renames correctly. This is now fixed with a new feature logical, DECC$RENAME_ALLOW_DIR. Enabling DECC$RENAME_ALLOW_DIR restores the earlier OpenVMS behavior of the rename() function by allowing conversion to a directory specification where the second argument is an ambiguous file specification passed as a logical name. Consider the following example with DECC$RENAME_ALLOW_DIR enabled: rename("file.ext", "logical_name") /* where logical_name = dev:[dir.subdir] */ /* and :[dir.subdir] exists This results in: dev:[dir.subdir]file.ext This example renames a file from one directory into another directory, which is the same behavior as in legacy versions of OpenVMS (versions before 7.3-1). Also in this example, if dev:[dir.subdir] does not exist, rename() returns an error. Disabling DECC$RENAME_ALLOW_DIR provides a more UNIX compliant conversion of the "logical_name" argument of rename(). Consider the following example with DECC$RENAME_ALLOW_DIR disabled: rename("file.ext", "logical_name") /* where logical_name = dev:[dir.subdir] */ This results in: HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 13 dev:[dir]subdir.ext This example renames the file using the subdir part of the "logical_name" argument as the new file name because on UNIX systems, renaming a file to a directory is not allowed. So rename() internally converts the "logical_name" to a file name, and dev:[dir]subdir is the most reasonable conversion it can perform. This new feature switch has a side effect of causing rename to a directory to take precedence over rename to a file. Consider this example: rename ( "file1.ext", "dir2" ) /* dir2 is not a logical */ With DECC$RENAME_ALLOW_DIR disabled, this example results in dir2.ext, regardless of whether or not subdirectory [.dir2] exists. With DECC$RENAME_ALLOW_DIR enabled, this example results in dir2.ext only if subdirectory [.dir2] does not exist. If subdirectory [.dir2] does exist, the result is [.dir2]file1.ext. Notes: o If DECC$RENAME_NO_INHERIT is enabled, UNIX compliant behavior is expected, so DECC$RENAME_ALLOW_DIR is ignored, and renaming a file to a directory is not allowed. o On failure, the rename() function returns -1 and sets errno to one of the following values: - EISDIR - The new argument points to a directory, and the old argument points to a file that is not a directory. - EEXIST - The new argument points to a directory that already exists. - ENOTDIR - The old argument names a directory, and the new argument names a non-directory file. Problems addressed in kit VMS73_ACRTL-V0500 Do not use the VMS73_ACRTL-V0500 ECO kit. Programs linked against the VMS73_ACRTL-V0500 ECO kit will be incompatible with OpenVMS Version 7.3-2 and will not run properly on OpenVMS 7.3-2. Use the VMS73_ACRTL-V0600 ECO kit instead. HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 14 Problems addressed in kit VMS73_ACRTL-V0400 The VMS73_ACRTL-V0400 was functionally equivalent to the VMS73_ACRTL-V0300 kit and had no additional bug fixes beyond those in the VMS73_ACRTL-V0300 kit. Problems addressed in kit VMS73_ACRTL-V0300 Unless otherwise stated, all problems were fixed. Note: The first several entries list new features in this ECO kit. For more information, see "New Features in kit VMS73_ACRTL-V0300." o C header files are shipped with this ECO kit. These files will be installed only if needed by your system. o You can now set the default (working) directory for child processes created by vfork/exec*, using the new RTL function decc$set_child_default_dir(). For more information, see the "New Features" section of the release notes for this ECO kit. o 64-bit pointer support is added for sendmsg(), recvmsg(), getaddrinfo(), and freeaddrinfo(). For more information, see the "New Features" section of the release notes for this ECO kit. o A new feature logical DECC$ALLOW_REMOVE_OPEN_FILES is added to control the behavior of remove() on open files. For more information, see the "New Features" section of the release notes for this ECO kit. o New C RTL functions are provided with this kit. The following new C RTL functions are provided with this kit: pread() pwrite() readv() _readv64() __writev64() decc$set_child_default_dir() For more information, see the "New Features" section of the release notes for this ECO kit. o New socket routine poll() is provided with this kit. For more information, see the "New Features" section of the release notes for this ECO kit. o Undefined symbol GETADDRINFO_COMPAT43 HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 15 In some circumstances, the OpenVMS linker flagged the GETADDRINFO_COMPAT43 symbol as undefined. This is fixed. o 64-bit pointers were not supported for some socket routines. The following socket routines did not have 64-bit pointer support. Now they do: accept() getpeername() getsockname() o fwrite() wrote inappropriate records to a file. In OpenVMS Version 7.3-1, a change was made to the way the C RTL wrote fixed-length records whose size was less than the record size defined for the file. In this case, the C RTL would pad the record with zeros to create a record size equal to the maximum record size defined for the file. Because this was a change in behavior, a feature logical should have been included to control this behavior. This feature logical has now been added. This new feature logical, DECC$WRITE_SHORT_RECORDS, supports the previous change to the fwrite() function while retaining the legacy way of writing records to a fixed-length file as the default behavior: With DECC$WRITE_SHORT_RECORDS enabled, short-sized records are padded with zeros to align records on record boundaries. With DECC$WRITE_SHORT_RECORDS disabled, the legacy behavior of writing records is implemented. This is the default behavior. o header was incompatible with local-time function ftw(). Recent versions of the C RTL, along with header files supplied with Version 6.5 of the C compiler, incorrectly made a local-time version of the ftw() function the default when compiling with the _VMS_V6_SOURCE macro defined. Fix: This behavior was incompatible with previous C RTL versions, and has been restored to default to the UTC-based ftw() function under the same circumstances. Now, to get the local-time ftw(), you must compile with /DEFINE=__LOCAL_TIME_FTW, in addition to the macros _VMS_V6_SOURCE and _DECC_V4_SOURCE. o Spawned process did not inherit file positioning for append access mode. For spawned processes that are C programs, defining the DECC$EXEC_FILEATTR_INHERITANCE feature logical name to a value of 1 or ENABLE no longer causes the spawned child process to inherit file positioning for all file access modes; specifically, append mode does not inherit file positioning. HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 16 Fix: For a child process to inherit file positioning for all file access modes including append, DECC$EXEC_FILEATTR_INHERITANCE must be set to a value of 2: $ DEFINE DECC$EXEC_FILEATTR_INHERITANCE 2 For a child process to inherit file positioning for all file access modes except append, set DECC$EXEC_FILEATTR_INHERITANCE to a value of 1: $ DEFINE DECC$EXEC_FILEATTR_INHERITANCE 1 This change was made in OpenVMS Version 7.3-1. This ECO propagates the fix to OpenVMS Versions 7.3 and 7.22. o Incomplete support for 64-bit iconv() has been removed. Incomplete support for 64-bit iconv() was mistakenly put into recent (Spring 2002) ECO kits and OpenVMS V7.3-1. This gave the illusion of 64-bit iconv() support under some circumstances (linking with STARLET.OLB). This was never supported, and still is not supported. Fix: Because 64-bit iconv() is neither functional nor supported, this ECO removes DECC$_ICONV64. Users compiling with /POINTER=LONG should now expect a compiler error message such as the following: %CC-W-PTRMISMATCH, In this statement, the referenced type of the pointer value "(char ...)0" is "long pointer to char", which is not compatible with "short pointer to char". New Features in kit VMS73_ACRTL-V0300 64-bit pointer support for some socket functions: 64-bit pointer support has been added for the sendmsg(), recvmsg(), getaddrinfo(), and freeaddrinfo() socket functions. Each of these existing functions takes as an argument a data structure that contains other data structures and embedded pointers. In order to provide pointer-size specific variants of these functions, explicit definitions have been added for 32-bit and 64-bit versions of the affected data structures. Consequently, the new explicit 32-bit and 64-bit variants for these functions expect to receive as an argument the corresponding 32-bit or 64-bit version of the associated data structures, as follows: HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 17 Function Variant Struct Argument ---------------- --------------- __sendmsg32() struct __msghdr32 __sendmsg64() struct __msghdr64 __recvmsg32() struct __msghdr32 __recvmsg64() struct __msghdr64 __getaddrinfo32() struct __addrinfo32 __getaddrinfo64() struct __addrinfo64 __freeaddrinfo32() struct __addrinfo32 __freeaddrinfo64() struct __addrinfo64 Previously, these functions had only a 32-bit interface. New feature logical DECC$ALLOW_REMOVE_OPEN_FILES added to control the behavior of remove() on open files. The DECC$ALLOW_REMOVE_OPEN_FILES feature logical is added to control the behavior of remove() on open files. Ordinarily, the operation fails. However, POSIX conformance dictates that the operation succeed. This POSIX conformant behavior is enabled by the new feature switch. New socket function poll(): poll() - Monitors conditions on multiple file descriptors Format #include int poll(struct pollfd fds[], nfds_t nfds, int timeout); Arguments fds An array of pollfd structures, one for each file descriptor of interest. Each pollfd structure includes the following members: int fd The file descriptor int events The requested conditions int revents The reported conditions nfds The number of pollfd structures in the fds array timeout The maximum length of time (in milliseconds) to wait for at least one of the specified events to occur Description The poll() function provides applications with a mechanism for multiplexing input/output over a set of file descriptors. For each member of the array pointed to by fds, poll() examines the given file descriptor for the event(s) specified HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 18 in events. The number of pollfd structures in the fds array is specified by nfds. The poll() function identifies those file descriptors on which an application can read or write data, or on which certain events have occurred. The fds argument specifies the file descriptors to be examined and the events of interest for each file descriptor. It is a pointer to an array with one member for each open file descriptor of interest. The array's members are pollfd structures within which fd specifies an open file descriptor, and events and revents are bitmasks constructed by OR-ing a combination of the following event flags: POLLIN Data other than high-priority data may be read without blocking. For STREAMS, this flag is set in revents even if the message is of zero length. POLLRDNORM Normal data (priority band equals 0) may be read without blocking. For STREAMS, this flag is set in revents even if the message is of zero length. POLLRDBAND Data from a nonzero priority band may be read without blocking. For STREAMS, this flag is set in revents even if the message is of zero length. POLLPRI High priority data may be received without blocking. For STREAMS, this flag is set in revents even if the message is of zero length. POLLOUT Normal data (priority band equals 0) may be written without blocking. POLLWRNORM Same as POLLOUT. POLLWRBAND Priority data (priority band > 0) may be written. If any priority band has been written to on this STREAM, this event only examines bands that have been written to at least once. POLLERR An error has occurred on the device or stream. This flag is only valid in the revents bitmask; it is ignored in the events member. POLLHUP The device has been disconnected. This event and POLLOUT are mutually exclusive; a stream can never be writable if a hangup has occurred. However, this event and POLLIN, POLLRDNORM, POLLRDBAND, or POLLPRI are not mutually exclusive. This flag is only valid HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 19 in the revents bitmask; it is ignored in the events member. POLLNVAL The specified fd value is invalid. This flag is only valid in the revents member; it is ignored in the events member. If the value of fd is less than 0, events is ignored and revents is set to 0 in that entry on return from poll(). In each pollfd structure, poll() clears the revents member except that where the application requested a report on a condition by setting one of the bits of events listed above, poll() sets the corresponding bit in revents if the requested condition is true. In addition, poll() sets the POLLHUP, POLLERR, and POLLNVAL flag in revents if the condition is true, even if the application did not set the corresponding bit in events. If none of the defined events have occurred on any selected file descriptor, poll() waits at least timeout milliseconds for an event to occur on any of the selected file descriptors. If the value of timeout is 0, poll() returns immediately. If the value of timeout is -1, poll() blocks until a requested event occurs or until the call is interrupted. Implementations can place limitations on the granularity of timeout intervals. If the requested timeout interval requires a finer granularity than the implementation supports, the actual timeout interval will be rounded up to the next supported value. The poll() function is not affected by the O_NONBLOCK flag. The poll() function supports regular files, terminal and pseudo-terminal devices, STREAMS-based files, FIFOs and pipes. The behavior of poll() on elements of fds that refer to other types of files is unspecified. Regular files always poll TRUE for reading and writing. Return Values positive value Upon successful completion, the total number of file descriptors selected (that is, file descriptors for which the revents member is nonzero). 0 Successful completion - The call timed out and no file descriptors were selected. -1 poll() failed; errno is set to indicate the error. Errors HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 20 Upon failure, poll() sets errno to one of the following values: [EAGAIN] The allocation of internal data structures failed but a subsequent request may succeed. [EINTR] A signal was caught during poll(). [EINVAL] The nfds argument is greater than {OPEN_MAX}, or one of the fd members refers to a STREAM or multiplexer that is linked (directly or indirectly) downstream from a multiplexer. New function pread(): pread() - Reads from a file Format #include ssize_t pread(int fildes, void *buf, size_t nbytes, off_t offset); Arguments fildes A file descriptor that refers to a file currently opened for reading. buf The address of contiguous storage in which the input data is placed. nbytes The maximum number of bytes involved in the read operation. offset The offset for the desired position inside the file. Description The pread() function performs the same action as read(), except that it reads from a given position in the file without changing the file pointer. The first three arguments to pread() are the same as for read(), with the addition of a fourth argument offset for the desired position inside the file. An attempt to perform a pread() on a file that is incapable of seeking results in an error. Return Values n The number of bytes read. -1 pread() failed; errno is set to indicate the error. Errors Upon failure, the file pointer remains unchanged and pread() HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 21 sets errno to one of the following values: [EINVAL] The offset argument is invalid. The value is negative. [EOVERFLOW] The file is a regular file and an attempt was made to read or write at or beyond the offset maximum associated with the file. [ENXIO] A request was outside the capabilities of the device. [ESPIPE] fildes is associated with a pipe or FIFO. New function pwrite(): pwrite() - Writes to a file Format #include ssize_t pwrite(int fildes, const void *buf, size_t nbytes, off_t offset); Arguments fildes A file descriptor that refers to a file currently opened for writing or updating buf The address of contiguous storage from which the output data is taken. nbytes The maximum number of bytes involved in the write operation. offset The offset for the desired position inside the file. Description The pwrite() function performs the same action as write(), except that it writes into a given position without changing the file pointer. The first three arguments to pwrite() are the same as for write(), with the addition of a fourth argument offset for the desired position inside the file. Return Values n The number of bytes written. -1 pwrite() failed; errno is set to indicate the error. Errors Upon failure, the file pointer remains unchanged and pread() sets errno to one of the following values: [EINVAL] The offset argument is invalid. The value is negative. HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 22 [ESPIPE] fildes is associated with a pipe or FIFO. New functions readv(), _readv64(): readv() - Reads from a file _readv64() - 64-bit variant of readv(). Format #include ssize_t readv(int fildes, const struct iovec *iov, int iovcnt); ssize_t _readv64(int fildes, struct __iovec64 *iov, int iovcnt); Arguments fildes A file descriptor that refers to a file currently opened for reading. iov Array of iovec structures into which the input data is placed. iovcnt The number of buffers specified by the members of the iov array. Description The readv() function is equivalent to read(), but places the input data into the iovcnt buffers specified by the members of the iov array: iov[0], iov[1], ..., iov[iovcnt-1]. The iovcnt argument is valid if it is greater than 0 and less than or equal to IOV_MAX. The _readv64() function is a variant of the readv() function for use with 64-bit pointer sizes. See Chapter 1 of the C RTL Reference Manual for more information on using pointer-size-specific functions. Each iovec entry specifies the base address and length of an area in memory where data should be placed. The readv() function always fills an area completely before proceeding to the next. Upon successful completion, readv() marks for update the st_atime field of the file. If the Synchronized Input and Output option is supported: If the O_DSYNC and O_RSYNC bits have been set, read I/O operations on the file descriptor will complete as defined by synchronised I/O data integrity completion. If the O_SYNC and O_RSYNC bits have been set, read I/O operations on the file descriptor will complete as defined by synchronised I/O file integrity completion. If the Shared Memory Objects option is supported: HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 23 If fildes refers to a shared memory object, the result of the read() function is unspecified. For regular files, no data transfer will occur past the offset maximum established in the open file description associated with fildes. Return Values n The number of bytes read. -1 readv() failed; errno is set to indicate the error. Errors Upon failure, the file pointer remains unchanged and pread() sets errno to one of the following values: [EAGAIN] The O_NONBLOCK flag is set for the file descriptor and the process would be delayed. [EBADF] The fildes argument is not a valid file descriptor open for reading. [EBADMSG] The file is a STREAM file that is set to control-normal mode and the message waiting to be read includes a control part. [EINTR] The read operation was terminated due to the receipt of a signal, and no data was transferred. [EINVAL] The STREAM or multiplexer referenced by fildes is linked (directly or indirectly) downstream from a multiplexer. [EIO] A physical I/O error has occurred, OR The process is a member of a background process attempting to read from its controlling terminal, the process is ignoring or blocking the SIGTTIN signal or the process group is orphaned. This error may also be generated for implementation-dependent reasons. [EISDIR] The fildes argument refers to a directory and the implementation does not allow the directory to be read using read(), pread() or readv(). The readdir() function should be used instead. [EOVERFLOW] The file is a regular file, nbyte is greater than 0, the starting position is before the end-of-file and the starting position is greater than or equal to the offset maximum established in the open file description associated with fildes. [EINVAL] The sum of the iov_len values in the iov array HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 24 overflowed an ssize_t. The readv() function might fail if: [EINVAL] The iovcnt argument was less than or equal to 0, or greater than IOV_MAX. New function variant __writev64(): __writev64() - Writes to a file Format #include ssize_t __writev64(int fildes, const struct __iovec64 *iov, int iovcnt); Description The __writev64() function is a variant of the writev() function for use with 64-bit pointer sizes. See Chapter 1 of the C RTL Reference Manual for more information on using pointer-size-specific functions. New function decc$set_child_default_dir(): decc$set_child_default_dir() - Sets the default directory for child processes. Format #include int decc$set_child_default_dir(const char *default_dir); Arguments default_dir The default directory for child procesess, or NULL (to restore default behavior). Description This function sets the default (working) directory for child processes created by calling vfork() followed by one of the exec*() family of functions. Ordinarily, in the absence of this function call, child processes inherit the default directory of their parent process. By calling decc$set_child_default_dir(), all child processes created with vfork/exec have their default directory set to default_dir when they begin execution. default_dir must represent a valid directory specification, or results of the call are unpredictable (the child process might fail without notification). Both OpenVMS and UNIX HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 25 style file specifications are supported for this function call. You can reset the inherited working directory to that of the parent by executing decc$set_child_default_dir(NULL); subsequently, all created child processes will inherit their parent's working directory, as is the normal default behavior for vfork/exec. Return Values 0 Successful completion. The new inherited default directory was established. Note, however, that although an invalid directory specification could result in a successful function call, a subsequent exec call might fail, perhaps without notification. -1 decc$set_child_default_dir() failed; no new default directory was established for child processes; errno is set. Errors Upon failure, decc$set_child_default_dir() sets errno to one of the following values: [ENOMEM] Insufficient memory [ENAMETOOLONG] default_dir is too long to issue the required SET DEFAULT command. Problems addressed in kit VMS73_ACRTL-V0200 Unless otherwise stated, all problems were fixed. o Large file support for I/O functions In previous releases of C RTL, all file positions were calculated using 32-bit arithmetic. This restricted certain file operations to file sizes less than 2GB. This restriction has now been removed. File operations using C RTL I/O may now be performed on file sizes up to 2 terabytes. By default, applications may only use offsets expressed in 32 bits. The function fgetpos() now returns the correct file offset when the file position is beyond 2GB. Developers can also program their application to express file sizes and positions in 64-bits. The new 64-bit interfaces can be selected at compile time by defining the _LARGEFILE feature macro: $ CC /DEFINE=_LARGEFILE HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 26 When specified, a 64-bit integer is used to express the integral type off_t. Support has been added for compiling applications to use file sizes and offsets that are 2 gigabytes or larger. This is accomplished by allowing file offsets of 64-bit integers. Two new functions have been added: - fseeko - ftello These are identical to fseek and ftell , but they accept or return values of type off_t , which allows for a 64-bit variant of off_t to be used. Modifications to accommodate a 64-bit file offset have been made to the following existing C RTL functions: - fstat - ftruncate - ftw - lseek - mmap - stat - truncate Note that ECO kits released in August 2000 and later for both VAX and Alpha had a problem with stream file larger than 2GB. Attempts to position at the beginning of file using rewind(), lseek() or fseek() may fail and leave the file position at end-of-file. In V7.3, this can cause an ACCVIO. This is also fixed. o GB18030 Chinese character support Support for the Chinese GB18030 character set was added to the C Run-Time for the VMSI18N Internationalization kit which also supports GB18030. This is one of two kits required for GB18030 support, the other is ALPVMSI18N01_073 on OpenVMS Alpha V7.3. This C Run-Time kit must be installed before the VMSI18N kit. o Function strftime() V conversion specifier returns incorrect weeks HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 27 The function strftime() V conversion specifier, did not return the correct number of weeks in the year for some boundary dates at the end of December or the beginning of January. o Function strftime() reported either week 52 or 53 for last week of December. It should report "1" for December dates which are in the same week as January 1st of the next year, when the week that contains Jan 1 has four or more days in the next year. o Function strftime() always reported week 53 when early January dates were not in week 1, even if the last week in December was actually week 52. They should be reported as week 52. o Threaded applications hang while opening files Threaded C applications can hang, when doing operations which result in file I/O. The frequency of the hang varies with the timing of statements in the user's program. Changing the program can eliminate the hang, especially adding extra I/O function calls. o Function ecvt() performance (high kernel mode) Function ecvt() (convert to string) had performance problems due to its use of thread-specific data. The function called LIB$AST_IN_PROG() protects the thread-specific data against corruption by an interrupting AST. LIB$AST_IN_PROG() introduces a high overhead resulting in poor performance. Function ecvt() was not intended to be AST-safe. The handling of thread-specific data was revised in C RTL for OpenVMS V7.1-1. This introduced the test for LIB$AST_IN_PROG() and the resulting overhead. The default is now thread-safe but not AST-safe. This greatly improves performance. The AST-safe mode can be restored by enabling the feature DECC$THREAD_DATA_AST_SAFE: $ DEFINE DECC$THREAD_DATA_AST_SAFE ENABLE o Function times() performance issues A C application can become noticeably slower after adding calls to C Run-Time function times() to get performance data. The times() function used an asynchronous system call $GETJPI which includes significant overhead. Function times() has been changed to take advantage of changes in OpenVMS which now make the call synchronous which HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 28 significantly reduces overhead. o Function alarm() issues Function alarm() did not correctly recognize an unexpired timer and did not always return the correct time remaining. Function alarm() supports a single timer. When another request to alarm() is issued, any pending request should be canceled, a new alarm scheduled and the time remaining on the original timer returned. Function alarm() was changed to: o Use static variable for storing scheduled alarm. o If the unexpired time is less than zero then report zero. o If the unexpired time is greater than zero then return a minimum of 1. o fopen() fails in exec mode When called from a higher access mode, function fopen() can fail with a Bad Address error. o File open context ctx=eol ignored Child processes did not inherit file open context "ctx=eol" when specified in the parent process. The child process inherits the file open contexts of the parent. It does this by interpreting the context and generating an open request with the reconstituted optional arguments. The algorithm for building the open request was not updated accordingly, and so this option was ignored. This has been fixed. o Support EFS charset in UNIX names C programs cannot create files with special characters such as '#' in UNIX mode. The CRTL requires a new feature logical DECC$EFS_CHARSET to be defined with the value ENABLE to use EFS extended characters. Many existing applications make assumptions about file names based on the presence of certain characters. This is necessary because non-standard and undocumented C RTL extensions do not work when EFS extended character set support is enabled. The existing feature logical DECC$FILENAME_UNIX_ONLY specifies filename interpretation. Two new feature logical have been created to enable some of these features independent of whether OpenVMS names are accepted. HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 29 * DECC$FILENAME_UNIX_ONLY - Always interpret names as UNIX style. Never interpret a name as a OpenVMS format name. This is the primary behavior when DECC$FILENAME_UNIX_ONLY is set to ENABLE. * DECC$FILENAME_UNIX_NO_VERSION - Ignore OpenVMS generation numbers and never treat the last element of a UNIX name as a generation number. This behavior can now be selected independently by enabling feature logical DECC$FILENAME_UNIX_NO_VERSION. * When not otherwise specified, always report file names in UNIX style. This behavior can now be selected independently by enabling feature logical DECC$FILENAME_UNIX_REPORT. The implementation supports conversion from OpenVMS to UNIX needed for readdir(), ftw(), getname(), fgetname(), and getcwd(), etc. o Functions stat() and fstat() issues Function fstat() is not reporting permissions for files of type S_IFCHR and reports that owner is owner of current process. Function fstat() leaves the XABITM block for XAB$_UCHAR_DIRECTORY linked to the FAB if $DISPLAY fails. This also affects stat(). o Function setvbuf() restricts max size to 32767 Function setvbuf() restricted maximun buffer size for stream files to 32767 instead of 65535. When setvbuf() is used on a file not opened by RMS, such as a socket, the application may ACCVIO. o Function pclose() doesn't return OpenVMS status Applications testing the return status of pclose() in OpenVMS mode cannot detect warnings. To check the OpenVMS status, compile with the _VMS_WAIT macro defined. This will enable OpenVMS Warning, Failure and Success conditions. $ cc/define=_VMS_WAIT This is similar to function waitpid(), where _VMS_WAIT is documented. HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 30 o Excessive library lookups for socket routines C programs calling sockets were slow because of how the CRTL was resolving entries for socket functions in TCP/IP shared libraries. o Locale printf() incorrect with negative values Extraneous thousands separator displayed for negative values when using locale support with printf(). For example, "-,999,999.00" instead of "-999,999.00". o Functions remove() and unlink() do not delete open files Functions remove() and unlink() cannot delete files that are open. This is expected to work, and has been fixed. o HOME and PATH variables converted to lower case The C RTL was unconditionally converting the values for PATH and HOME to lowercase. C RTL preserves case in command line arguments when DECC$ARGV_PARSE_STYLE is enabled and "SET PROC/PARSE_STYLE=EXTENDED" is in effect. It is appropriate that when command line arguments have case preserved that the environment variables HOME and PATH be treated likewise. o Function stat(), access() fails with file opened for non-shared write This was fixed. o access() returns success for W_OK on readonly device Function access() is not testing whether the device is software write-locked when a user requests write access. If device is write-locked, errno is set to EROFS and failure is now returned. o Various problems with temporary file support - tempnam() is required by the standard to offer at least 10,000 unique names. CRTL currently allows 156. - access() is called to determine if a file to be created exists. For tempnam() the name is always in OpenVMS-style. When OpenVMS style names are disabled, access() will always fail indicating that there is no matching file. - tmpnam() reports the new name in a static buffer, instead of a thread-specific buffer. HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 31 - When tempnam() is called repeatedly, no attempt is made to remember the last generated name. If a file is created for each call, the program will get slower as it tests for the existence for each created file. o Function ftw() and readdir() do not recognize 000000.DIR If the top level directory on a device contains file names which collate before 000000.DIR, ftw() and readdir do not detect that 000000.DIR is a special directory and will recursively search it. 000000.DIR is now recognized as the top level directory and treated appropriately. o Function rename() unable to rename files without file types Trying to rename() file xx.yy to zz gets filename zz.yy. Trying to rename() file xx.yy to .zz gets filename xx.zz. This problem has been fixed, but requires a C RTL feature logical set. The user will get zz or .zz, as they specified. For compatibility with existing programs the new behavior must be enabled using a feature logical name: $ DEFINE DECC$RENAME_NO_INHERIT ENABLE If DECC$RENAME_NO_INHERIT is enabled, the rename function tries to emulate UNIX. - There is some validation of old and new names to determine if they are directories and ensure that a directory name will be valid after the rename. - The effective new name does not inherit any elements from the old name. - rename is performed using RMS function SYS$RENAME. This mode is designed for UNIX style names. Validation is less complete for OpenVMS style names. If feature DECC$RENAME_NO_INHERIT is DISABLED, the rename function follows OpenVMS renaming policy. Apart from converting UNIX names to OpenVMS format, in this mode the underlying LIBRTL function LIB$RENAME_FILE performs most of the validation. o access(path, W_OK) fails w/o delete access A call to function "access(path, W_OK)" will fail if the file/directory does not have delete access enabled. HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 32 Write access to a directory is commonly tested to see if a file can be created in the directory. Directories on OpenVMS are not typically created with delete access. Change access() to allow access with write access. o Function getenv() with multithreading Function getenv() call could corrupt the stack and cause an ACCVIO in a multi-threading application. This has been fixed. o getch() will ACCVIO when receiving a long escape sequence Function getch() will ACCVIO for termination sequences longer than 8 bytes. This has been fixed. C RTL Feature Switches Described in VMS73_ACRTL-V0200 The C RTL now provides an extensive list of feature switches that can be set using DECC$ logical names. These switches affect a C application's behavior at run time. These features introduce new behaviors and also preserve old behaviors that have been deprecated. These features are generally enabled by setting a logical name to "ENABLE" and disabled by setting to "DISABLE". This works for the newly introduced features. $ DEFINE DECC$feature ENABLE $ DEFINE DECC$feature DISABLE NOTE Older features from earlier releases of the C Run-Time documented that "any equivalence string" would enable the features. While this is correct, Compaq recommends that users instead use "ENABLE" for all features enabled using logical names. This will avoid possible side effects if the feature switch is enhanced to allow both enabling and disabling with the logical name defined. In particular, avoid the following values for any feature documented as accepting "any equivalence string": o "DISABLE" o 0 (zero) o F o N HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 33 List of Features This is a complete list of user-controlled feature logical names. Some of these feature logical names may not apply to this ECO kit, if OpenVMS does not support the function described. Most of these feature logicals should be enabled or disabled using ENABLE or DISABLE, but some require specific numeric values. Please see reference section for more details. Below lists feature logicals by related category: Performance optimizations DECC$ENABLE_GETENV_CACHE DECC$LOCALE_CACHE_SIZE DECC$TZ_CACHE_SIZE Legacy behaviors DECC$V62_RECORD_GENERATION DECC$XPG4_STRPTIME DECC$THREAD_DATA_AST_SAFE DECC$WRITE_SHORT_RECORDS File attributes DECC$DEFAULT_LRL DECC$DEFAULT_UDF_RECORD DECC$FIXED_LENGTH_SEEK_TO_EOF Mailboxes DECC$MAILBOX_CTX_STM Changes for UNIX conformance DECC$STRTOL_ERANGE DECC$VALIDATE_SIGNAL_IN_KILL DECC$SELECT_IGNORES_INVALID_FD General UNIX Enchancements DECC$ARGV_PARSE_STYLE DECC$PIPE_BUFFER_SIZE DECC$STDIO_CTX_EOL DECC$USE_RAB64 Enchancements for UNIX style file names DECC$DISABLE_TO_VMS_LOGNAME_TRANSLATION DECC$EFS_CHARSET DECC$FILENAME_UNIX_NO_VERSION DECC$FILENAME_UNIX_REPORT DECC$READDIR_DROPDOTNOTYPE DECC$RENAME_NO_INHERIT Enhancements for UNIX style file attributes DECC$EFS_FILE_TIMESTAMPS DECC$EXEC_FILEATTR_INHERITANCE DECC$FILE_OWNER_UNIX DECC$FILE_PERMISSION_UNIX DECC$FILE_SHARING HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 34 UNIX compliance mode DECC$FILENAME_UNIX_ONLY DECC$POSIX_STYLE_UID DECC$USE_JPI$_CREATOR DECC$DETACHED_CHILD_PROCESS New behaviors for POSIX conformance DECC$POSIX_SEEK_STREAM_FILE DECC$UMASK DECC$ALLOW_REMOVE_OPEN_FILES File name handling DECC$READDIR_KEEPDOTDIR DECC$EFS_CASE_SPECIAL DECC$UNIX_PATH_BEFORE_LOGNAME DECC$DISABLE_POSIX_ROOT Reference List of Features Below is an alphabetical list of all C Run-Time feature logical names. Unless otherwise stated, they are enabled with ENABLE and disabled with DISABLE. DECC$ALLOW_REMOVE_OPEN_FILES The DECC$ALLOW_REMOVE_OPEN_FILES feature logical controls the behavior of remove() on open files. Ordinarily, the operation fails. However, POSIX conformance dictates that the operation succeed. With DECC$ALLOW_REMOVE_OPEN_FILES enabled, this POSIX conformant behavior is achieved. DECC$ARGV_PARSE_STYLE With DECC$ARGV_PARSE_STYLE enabled, case is preserved in command line arguments when the process has been set up for extended DCL parsing using SET PROCESS/PARSE=EXTENDED. This must be defined externally as a logical name or set in a function called using the LIB$INITIALIZE mechanism because it is evaluated before function main() is called. DECC$DEFAULT_LRL DECC$DEFAULT_LRL specifies the default value for the RMS attribute for longest record length. The default value 32767 is the largest record size supported by RMS. Default: 32767 HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 35 Max: 32767 DECC$DEFAULT_UDF_RECORD With DECC$DEFAULT_UDF_RECORD enabled, file access mode defaults to RECORD instead of STREAM mode for all files except STREAMLF. DECC$DETACHED_CHILD_PROCESS With DECC$DETACHED_CHILD_PROCESS enabled, child processes created using vfork() and exec() are created as detached processes instead of subprocesses. This feature has only limited support. In some cases the console cannot be shared between the parent process and the detached process which can cause exec() to fail. DECC$DISABLE_POSIX_ROOT With DECC$DISABLE_POSIX_ROOT enabled, support for the POSIX root directory defined by SYSPOSIX_ROOT is disabled. With DECC$DISABLE_POSIX_ROOT is not enabled, logical name SYS$POSIX_ROOT is interpreted as the equivalent of the file path "/". If a UNIX path starting with '/' is given and the value after the leading slash cannot be translated as a logical name, SYS$POSIX_ROOT is used as the parent directory for the specified UNIX file path. DECC$DISABLE_TO_VMS_LOGNAME_TRANSLATION With DECC$DISABLE_TO_VMS_LOGNAME_TRANSLATION enabled, the conversion routine decc$to_vms() will only treat the first element of a UNIX style name as a logical name if there is a leading slash '/'. DECC$EFS_CASE_SPECIAL With DECC$EFS_CASE_SPECIAL enabled, case is only preserved for file names containing lowercase. If an element of a file name contains all uppercase letters, it is reported in all lowercase in UNIX style. When enabled, this feature overrides the value of DECC$EFS_CASE_PRESERVE. DECC$EFS_FILE_TIMESTAMPS With DECC$EFS_FILE_TIMESTAMPS enabled, stat() and fstat() report new ODS-5 access time (st_atime), attribute revision time (st_ctime) and modification time (st_mtime) HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 36 for files on ODS-5 volumes which have the extended file times enabled using SET VOLUME/VOLUME=ACCESS_DATES. If the feature is disabled or the volume is not ODS-5 or the volume does not have support for these additional times enabled, st_ctime continues to be the file creation time and st_atime the same as the st_mtime. Functions utime() and utimes() support these ODS-5 times in the same way as stat(). DECC$ENABLE_GETENV_CACHE The C RTL supplements the list of environment variables in table environ with all logical names and DCL symbols available to the process. By default, whenever getenv() is called for a name not in the environ table, an attempt is made to resolve this as a logical name and if this fails, as a DCL symbol. With DECC$ENABLE_GETENV_CACHE enabled, once a logical name or DCL name has been successfully translated, its value is stored in a cache. When the same name is requested in a future call to getenv(), the value is returned from the cache instead of re-evaluating the logical name or DCL symbol. DECC$EFS_CHARSET With DECC$EFS_CHARSET enabled, UNIX names may contain ODS-5 extended characters. Support includes multiple dots and all ASCII characters in range 0-255 except: - - / - " - * - ? Unless DECC$FILENAME_UNIX_ONLY enabled, some characters may be interpreted as VMS characters depending on context. These are - : - [ - < - ^ - ; DECC$EFS_CHARSET is required because Many existing applications make assumptions about file names based on the presence of certain characters. This is necessary because non-standard and undocumented C RTL extensions do not work when EFS extended character set support is enabled. HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 37 the following non-standard and undocumented C RTL extensions do not work when EFS extended character set support is enabled. - "$HOME" interpreted as the user's login directory With DECC$EFS_CHARSET enabled, "$HOME" is treated literally and may be in a VMS or UNIX style file name. - "~name" interpreted as the login directory for user "name" With DECC$EFS_CHARSET enabled, "~name" is treated literally and may be in an OpenVMS or UNIX style file name. - Wild card regular expressions in the form "[a-z]" With DECC$EFS_CHARSET enabled, square brackets are acceptable in VMS and UNIX style file names. For instance, in a function such as open(), "abc[a-z]ef.txt" is interpreted as a UNIX style name equivalent to the VMS style name "abc^[a-z^]ef.txt" and "[a-z]bc" is interpreted as a VMS style name equivalent to the UNIX style name "/sys$disk/a-z/bc". When support for EFS character set is enabled, the following encoding for EFS extended characters is supported when converting from a VMS style file name to a UNIX style file name. - All ODS-2 compatible names - All encoding for 8-bit characters, either as single byte or using two-digit hexadecimal form "^ab". In a UNIX path these are always represented as a single byte. - Encoding for DEL (^7F) - The following characters when preceded by caret: "Space !,_&'()+@{},';#[]%^=$-~." - The following characters when not preceded by caret: "$-~." The implementation supports conversion from VMS to UNIX needed for readdir(), ftw(), getname(), fgetname(), and getcwd(), etc. HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 38 DECC$EXEC_FILEATTR_INHERITANCE The following description is new for ECO kit VMS73_ACRTL-V0400. The DECC$EXEC_FILEATTR_INHERITANCE feature logical affects child processes that are C programs: With DECC$EXEC_FILEATTR_INHERITANCE defined to 1, a child process inherits file positioning for all file access modes except append. With DECC$EXEC_FILEATTR_INHERITANCE defined to 2, a child process inherits file positioning for all file access modes including append. With DECC$EXEC_FILEATTR_INHERITANCE disabled, a child process does not inherit the file position for any access modes. DECC$FILENAME_UNIX_ONLY With DECC$FILENAME_UNIX_ONLY enabled, file names are never interpreted as VMS style names. This prevents any interpretation of ':', '[' and '^', as VMS special characters. DECC$FILENAME_UNIX_NO_VERSION With DECC$FILENAME_UNIX_NO_VERSION enabled, VMS generation numbers are not supported in UNIX style file names. With this logical name disabled, in UNIX style names, generation numbers are reported preceded by a dot. DECC$FILENAME_UNIX_REPORT With DECC$FILENAME_UNIX_REPORT enabled, all file names are reported in UNIX style unless the caller specifically selects VMS-style. This applies to getpwnam(), getpwuid(), argv[0], getname(), and fgetname(). With this logical name disabled, unless specified in the function call, file names are reported in VMS style. DECC$FILE_PERMISSION_UNIX With DECC$FILE_PERMISSION_UNIX enabled, the file permissions for new files and directories are set according to the file creation mode and umask(). This includes mode 0777. When an earlier version of the file exists the file permissions for the new file are HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 39 inherited from this. This mode sets DELETE permission for a new directory when WRITE permission is enabled. With this logical name disabled, modes zero and 0777 indicate using RMS default protection or protection from the previous version of the file. Permissions for new directories also follow VMS rules, including disabling DELETE permissions. DECC$FILE_OWNER_UNIX With DECC$FILE_OWNER_UNIX enabled, the owner for a new file or directory is always based on the effective UIC. When an earlier version of the file exists, the owner for the new file is inherited from this. With this logical name disabled, the owner for a new file is set following VMS rules and may inherit the owner from the parent directory. DECC$FILE_SHARING With DECC$FILE_SHARING enabled, all files are opened with the full sharing enabled (FAB$M_DEL | FAB$M_GET | FAB$M_PUT | FAB$M_UPD). This is set as a logical OR with any sharing mode specified by the caller. DECC$FIXED_LENGTH_SEEK_TO_EOF With DECC$FIXED_LENGTH_SEEK_TO_EOF enabled, lseek(), fseeko() and fseek() with 'direction' paremeter set to SEEK_END will position relative to the last byte in the file for files with fixed length records. With this logical name disabled, lseek(), fseek() and fseeko(), when called with SEEK_EOF on files with fixed length records, will position relative to the end of the last record in the file. DECC$LOCALE_CACHE_SIZE DECC$LOCALE_CACHE_SIZE defines how much memory in bytes should be allocated for caching locale data. The default value is 0, which disables the locale cache. Max: 2147483647 DECC$MAILBOX_CTX_STM By default, open() on a local mailbox that is not a pipe treats mailbox records as having record attribute FAB$M_CR. HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 40 With DECC$MAILBOX_CTX_STM enabled, the record attribute FAB$M_CR is not set. DECC$PIPE_BUFFER_SIZE The system default buffer size of 512 bytes for pipe write operations can limit performance and generate extra line feeds when handling messages longer than 512 bytes. DECC$PIPE_BUFFER_SIZE allows a larger default buffer size to be used for pipe functions such as pipe() and popen(). Valid values for the buffer size in bytes are in the range 512 to 65024. If DECC$PIPE_BUFFER_SIZE is not specified, the default buffer size 512 is used. Default: 512 Min: 512 Max: 65536 DECC$POSIX_SEEK_STREAM_FILE With DECC$POSIX_SEEK_STREAM_FILE enabled, positioning beyond end-of-file on STREAM files will not write to the file until the next write. If the write is beyond the current end-of-file, this positions beyond the old end-of-file and the start position for the write are filled with zeroes. With this logical name disabled, positioning beyond end-of-file will immediately write zeroes to the file from the current end-of-file to the new position. DECC$POSIX_STYLE_UID With DECC$POSIX_STYLE_UID enabled, UIDs and 32-bit GIDs are interpreted as POSIX style identifiers. With this logical name disabled, UIDs and GIDs are derived from the process UIC. This feature is only available on VMS systems providing POSIX style UID and GID support. DECC$READDIR_DROPDOTNOTYPE With DECC$READDIR_DROPDOTNOTYPE enabled, readdir() when reporting files in UNIX style, only reports the trailing dot for files with no file type, when the file name contains a dot. With this logical name disabled, all files without a file type are reported with a trailing dot. HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 41 DECC$READDIR_KEEPDOTDIR The default behavior when reporting files in UNIX style from readdir() is to report directories without a file type. With DECC$READDIR_KEEPDOTDIR enabled, directories are reported in UNIX style with the file type ".DIR". DECC$RENAME_NO_INHERIT With DECC$RENAME_NO_INHERIT enabled, the new name for the file does not inherit anything from the old name. The new name must be specified completely. For example: Renaming "A.A" to "B." yields "B." With this logical name disabled, you get the expected OpenVMS behavior. For example: Renaming "A.A" to "B." yields "B.A" DECC$SELECT_IGNORES_INVALID_FD With DECC$SELECT_IGNORES_INVALID_FD enabled, select() will fail with errno set to EBADF when an invalid file descriptor is specified in one of the descriptor sets. With this logical name disabled, select() ignores invalid file descriptors. DECC$STDIO_CTX_EOL With DECC$STDIO_CTX_EOL enabled, writing to stdout and stderr for stream access is differed until a terminator is seen or the buffer is full. With this logical name disabled, each fwrite() generates a separate write, which for mailbox and record files generates a separate record. DECC$STRTOL_ERANGE With DECC$STRTOL_ERANGE enabled, strtol() behavior for error ERANGE is corrected to consume all remaining digits in the string. With this logical name disabled, the legacy behavior of leaving the pointer at the failing digit is preserved. HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 42 DECC$THREAD_DATA_AST_SAFE The C RTL has a mode that allocates storage for thread-specific data allocated by threads at non-AST level separate for data allocated for ASTs. In this mode, each access to thread-specific data requires a call to LIB$AST_IN_PROG(), which can add significant overhead when accessing thread-specific data in the C RTL. The alternate mode protects thread specific-data only if another function has it locked. This protects data that is in use within the C RTL but does not protect the caller from an AST changing the data pointed to. This latter mode is now the C RTL default for functions strtok(), ecvt() and fcvt(). The legacy AST safe mode can be selected by enabling DECC$THREAD_DATA_AST_SAFE. DECC$TZ_CACHE_SIZE DECC$TZ_CACHE_SIZE specifies the number of timezones that can be held in memory. Default: 2 Max: 2147483647 DECC$UMASK DECC$UMASK specifies the default value for the permission mask umask(). By default, a parent C program sets the umask() from the RMS default permissions for the process. A child process inherits the parent's value for umask(). To enter the value as an octal value, add the leading zero. Otherwise it will be translated as a decimal value. For example, $ DEFINE DECC$UMASK 026 Max: 0777 DECC$UNIX_PATH_BEFORE_LOGNAME With DECC$UNIX_PATH_BEFORE_LOGNAME enabled, when translating a UNIX file name not starting with a leading slash (/), an attempt is made to match this to a file or directory in the current directory. If this is not found and the name is valid as a logical name in a VMS file name, an attempt is made to translate the logical name, and if found, is used as part of the resulting file name. When DECC$UNIX_PATH_BEFORE_LOGNAME is enabled, it overrides the setting for DECC$DISABLE_TO_VMS_LOGNAME_TRANSLATION. HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 43 DECC$USE_JPI$_CREATOR When enabled, DECC$USE_JPI$_CREATOR determines the parent process ID in getppid() by calling $GETJPI using item JPI$_CREATOR instead of JPI$_OWNER. This feature is only available on systems supporting POSIX style session identifiers. DECC$USE_RAB64 With DECC$USE_RAB64 enabled, open functions allocate a RAB64 structure instead of the traditional RAB structure. This provides latent support for file buffers in 64-bit memory. DECC$VALIDATE_SIGNAL_IN_KILL With DECC$VALIDATE_SIGNAL_IN_KILL enabled, a signal value in the range but not supported by C RTL for OpenVMS will generate an error with errno set to EINVAL, which makes the * behavior the same as for raise(). With this logical name disabled, validation of signals is restricted to checking the signal value is in the range 0 to _SIG_MAX. If sys$sigprc() fails, errno will be set based on sys$sigprc() exit status. DECC$V62_RECORD_GENERATION OpenVMS 6.2 and 7.0 (and later) can output record files using different rules. With DECC$V62_RECORD_GENERATION enabled, the output mechanism follows the rules used on OpenVMS V6.2. DECC$WRITE_SHORT_RECORDS The DECC$WRITE_SHORT_RECORDS feature logical supports a previous fix to fwrite() (to accommodate short-sized records), while retaining the legacy way of writing records to a fixed-length file as the default behavior: With DECC$WRITE_SHORT_RECORDS enabled, short-sized records are padded with zeros to align records on record boundaries. With this logical name disabled, the legacy behavior of writing records is implemented. This is the recommended and default behavior. HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 44 DECC$XPG4_STRPTIME XPG5 support for strptime() introduces pivoting year support so that years in the range 0-68 are in the 21st century, and years in the range 69-99 are in the 20th century. With DECC$XPG4_STRPTIME enabled, XPG5 support for the pivoting year is disabled and all years in the range 0-99 in the current century. Enhanced Support for UNIX Style File Names The Compaq C RTL can accept UNIX style file and directory path names that contain the extended ASCII character set supported by OpenVMS Extended File Specifications (EFS) on ODS-5 devices. NOTE This feature is intended for use by applications ported from UNIX systems and not for native OpenVMS applications. To enable this feature, define the DECC$FILENAME_UNIX_ONLY logical name to ENABLE before program execution: $ DEFINE DECC$FILENAME_UNIX_ONLY ENABLE With this feature enabled, all file and path specifications input to the Compaq C RTL are assumed to be UNIX style and therefore can consist of the full, printable ASCII character set (20-7E hexadecimal), with the following exceptions: * (asterisk) ? (quotation mark) / (forward slash) " (double quotation mark) The Compaq C RTL provides any necessary enclosing quotation marks for special characters when presenting the file specification to the OpenVMS file system. OpenVMS file and path specifications that are output by the Compaq C RTL are converted to UNIX style where appropriate, and any special characters quoted by the OpenVMS file system are unquoted before being returned to the Compaq C RTL caller. In addition, the OpenVMS version-number field is stripped from the file name on output. For example, assume the following UNIX style path name is input: ./abc.d/data.dat.dat The Compaq C RTL converts it to the following before passing it on to the OpenVMS file system: HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 45 [.abc^.d]data^.dat.dat The caret (^) character is the EFS quote or escape character. (For more information about escape characters and name and type delimiters, see the Guide to OpenVMS File Applications.) When this file name is retrieved, it is output to the Compaq C RTL caller just as it was input, with quoted characters unquoted. Note that under normal Compaq C RTL parsing rules, an OpenVMS version field in a UNIX style input file name is passed directly to the file system. Therefore, the following example accesses version number 3 of the file with name data and type dat : data.dat;3 With the new feature, this file name is passed to the OpenVMS file system as the following (a file with name data and type dat;3 ): data.dat^;3 The OpenVMS version number associated with the file is not returned on output. The scope of this feature applies to allowable characters in both the directory and file-name fields of a UNIX style specification. Enabling this feature does not affect other features of the Compaq C RTL UNIX-to-OpenVMS and OpenVMS-to-UNIX path conversion. If logical-name expansion of the first element in the UNIX specification is enabled, the Compaq C RTL does not quote any special characters that appear in the logical-name equivalence string before presentation to the file system. POSIX Root Support Support has been added to provide OpenVMS with a UNIX style root that behaves like a real directory. This allows such actions as the following: % cd / % mkdir /dirname % tar -xvf tarfile.tar /dirname % ls / Previously, the C RTL did not recognize the slash (/) character as a directory name. The normal processing for a file path starting with the slash character was to interpret the first element as a logical name or device name. If this failed, there was special processing for the name /dev/null and names starting with /bin and /tmp : /dev/null NLA0: /bin SYS$SYSTEM: /tmp SYS$SCRATCH: HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 46 These behaviors are retained for compatibility purposes. In addition, support has been added to the C RTL for the logical name SYS$POSIX_ROOT as an equivalent to the slash character. To enable this feature for use by the C RTL, define SYS$POSIX_ROOT as a concealed logical name. For example: $ DEFINE/TRANSLATION=(CONCEALED,TERMINAL) SYS$POSIX_ROOT - "$1$DKA0:[SYS0.abc.]" To disable this feature, enter the following command: $ DEFINE DECC$DISABLE_POSIX_ROOT {1, ENABLE 0, DISABLE} Enabling SYS$POSIX_ROOT results in the following behavior: If the existing translation of a UNIX path starting with the / character fails and SYS$POSIX_ROOT is defined, the name is interpreted as if it starts with /sys$posix_root . When converting from an OpenVMS to a UNIX style file name, and the OpenVMS name starts with SYS$POSIX_ROOT:, then the SYS$POSIX_ROOT: portion is removed. For example, SYS$POSIX_ROOT:[dirname] becomes /dirname . If the resulting name could be interpreted as a logical name or as one of the special cases listed, the result is /./dirname instead of /dirname . 32-Bit Group Identifiers The C RTL supports 32-bit user identification (UID) and group identification (GID). 32-bit UID and GID support was added to some versions of the OpenVMS operating system to provide support for POSIX style identifiers. Although current versions of OpenVMS does not support POSIX style IDs, they do support 32-bit UID and GID. When an application is compiled to use 32-bit UID/GID, the UID and GID are derived from the UIC, as in previous versions of the operating system. In some cases, such as with the getgroups function, more information might be returned when the application supports 32-bit GIDs. To compile an application for 32-bit UID or GID support, define the macro __USE_LONG_GID_T. To compile an application for 16-bit UID or GID support, define the macro _DECC_SHORT_GID_T. In addition, although you cannot compile with POSIX style IDs enabled on current versions of OpenVMS, you can run programs that were compiled with POSIX style IDs enabled on OpenVMS systems that do provide that support. HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 47 Kit Installation Rating The following kit installation rating, based upon current CLD information, is provided to serve as a guide to which customers should apply this remedial kit. (Reference attached Disclaimer of Warranty and Limitation of Liability Statement) INSTALLATION RATING: 3 : To be installed by customers experiencing the problems corrected. Installation Instructions Install this kit with the POLYCENTER Software Installation Utility by logging into the SYSTEM account, and typing the following at the DCL prompt: $ PRODUCT INSTALL VMS73_ACRTL/SOURCE= The kit location may be a tape drive, CD, or a disk directory that contains the kit. If /SOURCE is not specified, the utility searches in the location defined by the logical name PCSI$SOURCE. If PCSI$SOURCE is not defined, and the /SOURCE qualifier is not specified, the POLYCENTER Software Installation utility searches the current default directory. Because the images in this kit will not take effect until the system is rebooted, you must reboot the system after installing this kit. If you have other nodes in your OpenVMS cluster, they must also be rebooted in order to make use of the new image(s). If it is not possible or convenient to reboot the entire cluster at this time, a rolling re-boot may be performed. Special Installation Instructions: %INSTALL-E-NODELSHRADR Error Message During installation you may see the following message: %INSTALL-E-NODELSHRADR, unable to delete image with shareable address data -INSTALL-I-PLSREBOOT, please reboot to install a new version of this image This is not a cause for concern. It simply means that DECC$SHR.EXE was installed as a resident image, which is the standard configuration for OpenVMS Alpha systems. The new image will not take effect until the system is rebooted. HP C Runtime for OpenVMS Alpha V7.3 ECO Release Notes Page 48 Scripting of Answers to Installation Questions During installation, this kit will ask and require user response to several questions. If you wish to automate the installation of this kit and avoid having to provide responses to these questions, you must create a DCL command procedure that includes the following definitions and commands: - $ DEFINE/SYS NO_ASK$BACKUP TRUE - $ DEFINE/SYS NO_ASK$REBOOT TRUE - Add the following qualifiers to the PRODUCT INSTALL command and add that command to the DCL procedure. /PROD=DEC/BASE=AXPVMS/VER=V6.0 - De-assign the logicals assigned For example, a sample command file to install the VMS73_ACRTL-V0600 kit would be: $ $ DEFINE/SYS NO_ASK$BACKUP TRUE $ DEFINE/SYS NO_ASK$REBOOT TRUE $! $ PROD INSTALL VMS73_ACRTL/PROD=DEC/BASE=AXPVMS/VER=V6.0 $! $ DEASSIGN/SYS NO_ASK$BACKUP $ DEASSIGN/SYS NO_ASK$REBOOT $! $ exit