Minutes of the 3 March 2011 Teleconference Austin-514 Page 1 of 1 Submitted by Andrew Josey, The Open Group. March 5 , 2011 Attendees Andrew Josey, The Open Group Don Cragun, PASC OR Nick Stoughton, USENIX, ISO/IEC OR Geoff Clare, The Open Group Mark Brown, IBM, TOG OR Eric Blake, Red Hat Jim Pugsley, Oracle *Old Business carried forward: TC1 PAR: Andrew reported that he has now submitted the PAR to IEEE. Subject to Lowell approving the submission, this is scheduled to be on the NESCOM agenda for the May 6 2011 meeting. * New Business * We picked up on regular Bug processing Bug 0000251: Forbid bytes 1 through 31 (inclusive) in filenames http://austingroupbugs.net/view.php?id=251 Don had some additional queries about this item, specifically related to readdir() and its handling of filenames with newlines in them. It was agreed that we will also point all related bugs to refer to bug 251, so when we wrap it up we will also be able to wrap up the other bugs. Bug 0000162: Determining System Endianess during Preprocessing Accept as marked http://austingroupbugs.net/view.php?id=162 Nick had completed his action after the last meeting. The item is tagged for Issue 8, no interpretation is needed. Add the following to XBD in the correct alphabetic location (after dlfcn.h, before errno.h): NAME endian.h - system endianness SYNOPSIS #include DESCRIPTION The header shall define at least the following macros for use in determining host byte order for integer types: BYTE_ORDER this macro shall have a value equal to one of the *_ENDIAN macros in this header. LITTLE_ENDIAN if BYTE_ORDER == LITTLE_ENDIAN, the host byte order is from least significant to most significant. BIG_ENDIAN if BYTE_ORDER == BIG_ENDIAN, the host byte order is from most significant to least significant. These macros shall be suitable for use in #if preprocessing directives. The macros BIG_ENDIAN and LITTLE_ENDIAN shall have distinct values. Implementations may define other macros with the _ENDIAN suffix. The following shall be declared as functions, or defined as macros, or both. If functions are declared, function prototypes shall be provided. uint16_t htobe16(uint16_t host_16bits); uint16_t htole16(uint16_t host_16bits); uint16_t be16toh(uint16_t big_endian_16bits); uint16_t le16toh(uint16_t little_endian_16bits); uint32_t htobe32(uint32_t host_32bits); uint32_t htole32(uint32_t host_32bits); uint32_t be32toh(uint32_t big_endian_32bits); uint32_t le32toh(uint32_t little_endian_32bits); uint64_t htobe64(uint64_t host_64bits); uint64_t htole64(uint64_t host_64bits); uint64_t be64toh(uint64_t big_endian_64bits); uint64_t le64toh(uint64_t little_endian_64bits); The header shall define the uint64_t, uint32_t and uint16_t types as described in . Inclusion of the header may also make visible all symbols from . APPLICATION_USAGE None RATIONALE Many implementations also include PDP_ENDIAN to indicate a byte ordering where each pair of bytes is swapped. If BIG_ENDIAN is defined as 4321, PDP_ENDIAN would be 3412. However, this scheme is not universal, and derives its name from an obsolete processor. FUTURE DIRECTION None. SEE ALSO XSH: htonl(), swab() CHANGE HISTORY Added at Issue 8 =============================== Add a "Suffix" column to the table on P473. Change line 16039 to read: "If any header in the following table is included, macros with the prefixes or suffixes shown may be defined." Add to the modified table on P473: Header Prefix Suffix _ENDIAN =============================== Add a new page to XSH for be16toh(), and pointer pages for the other functions listed here: NAME be16toh, be32toh, be64toh, htobe16, htobe32, htobe64, htole16, htole32, htole64, le16toh, le32toh, le64toh SYNOPSIS #include uint16_t htobe16(uint16_t host_16bits); uint16_t htole16(uint16_t host_16bits); uint16_t be16toh(uint16_t big_endian_16bits); uint16_t le16toh(uint16_t little_endian_16bits); uint32_t htobe32(uint32_t host_32bits); uint32_t htole32(uint32_t host_32bits); uint32_t be32toh(uint32_t big_endian_32bits); uint32_t le32toh(uint32_t little_endian_32bits); uint64_t htobe64(uint64_t host_64bits); uint64_t htole64(uint64_t host_64bits); uint64_t be64toh(uint64_t big_endian_64bits); uint64_t le64toh(uint64_t little_endian_64bits); DESCRIPTION These functions convert integer values of various sizes between host representations and representations in a specified order. On some implementations, these functions are defined as macros. A little-endian representation of an integer has the least significant byte stored as the first byte, with the significance of the bytes increasing as the byte address increases. A big endian representation has the most significant byte as the first byte, with the significance of the bytes reducing as the byte address increases. NOTE: network byte order is "big-endian". For example, the uint32_t value 0x01020304 is represented as the four bytes 0x04, 0x03, 0x02, 0x01 on a little endian host, and as 0x01, 0x02, 0x03, 0x04 on a big endian host. For each of the sizes 16, 32 and 64, the htobeSIZE function shall convert from whatever order the host uses to big endian representation, htoleSIZE shall convert to little endian representation, beSIZEtoh shall convert from big endian to host order, and leSIZEtoh shall convert from little endian to host order. RETURN VALUE These functions shall return an unsigned integer of the appropriate size and representation. ERRORS No errors are defined. EXAMPLES #include #include #include int main(int argc, char *argv[]) { uint32_t val; if (argc > 1) { val = (uint32_t)strtoul(argv[1], NULL, 0); printf("Value: %08x\n", val); printf("As bytes:\n"); union { uint32_t asint; unsigned char asbytes[sizeof(uint32_t)]; } u; printf("Little endian: "); u.asint = htole32(val); for (int i = 0; i < sizeof(uint32_t); i++) { printf("%02x ", u.asbytes[i]); } printf("\n"); printf("Big endian : "); u.asint = htobe32(val); for (int i = 0; i < sizeof(uint32_t); i++) { printf("%02x ", u.asbytes[i]); } printf("\n"); } return 0; } APPLICATION USAGE Since network order is defined as big endian, the following functions are equivalent if is included: htobe32 htonl htobe16 htons be32toh ntohl be16toh ntohs RATIONALE None FUTURE DIRECTIONS None SEE ALSO htonl() XBD CHANGE HISTORY Added at Issue 8 Add to arpa/inet.h SEE ALSO page 222 line 7299: Add to htonl, page 1097, line 36617: be16toh and to line 36618: Bug 0000387: Remove obsolete commands from POSIX standard: admin, delta, get, prs, rmdel, sact, sccs, unget, val, uucp, uustat, uux, asa. Reject http://austingroupbugs.net/view.php?id=387 This item was rejected as the utilities listed are optional and there are reasons to leave them in the specification as is . See the responses to the bug for further detail. Bug 0000382: may strerror(0) fail with EINVAL? OPEN http://austingroupbugs.net/view.php?id=382 Don agreed to take an action to propose a response. Next Steps ---------- The next call will be on March 10th at 08:00 Pacific and will continue processing defect reports. This call will be for the regular 90 minutes. http://austingroupbugs.net See the calendar for the list of dialup numbers. An IRC channel will be available for the meeting irc://irc.freestandards.org #austin ICAL: http://www.google.com/calendar/ical/nvctqtstkuni3fab9k3jqtrt4g@group.calendar.google.com/public/basic XML: http://www.google.com/calendar/feeds/nvctqtstkuni3fab9k3jqtrt4g@group.calendar.google.com/public/basic