PROBLEM: (66873, 80677, 80944, 89050, 89274, 91627, 94285) (PATCH ID: OSF520-901) ******** The getdate() function uses mktime() to normalize the tm struct being generated for it's input data. However, getdate() was not properly checking both the return value and errno for a potential out-of-range indication from it's mktime() call. This patch fixes this problem. The strptime() routine matches input incorrectly to the format string. According to the Single UNIX Spec for strptime(), "Any other conversion specification is executed by scanning characters until a character matching the next directive is scanned, or until no more characters can be scanned." Instead, the strptime() routine makes assumptions of how many characters to scan based on the number of digits in the maximum value for that particular conversion specification. This algorithm does not give consistent results and does not follow the Single UNIX Spec. This patch modifies the parsing algorithm to provide full compliance. The strptime() routine matches white space incorrectly to %n and %t. It matches white space up to the first tab character for %t and matches white space up to the first newline character for %n. The Single UNIX Spec for strptime defines both %n and %t as "is any white space". This patch fixes strptime() so it matches any white space to both %n and %t. The callrpc() routine tracks information related to an rpc call, including the socket used for communication and a valid field. If the valid flag is false, the code closes the socket. In some instances, this results in closing sockets not owned by the process. This patch modifies callrpc() to track whether or not the process has opened the socket. The socket is closed only if this field indicates that the socket is owned by the process. Uses of fork()/popen() can trigger "inconsistent order" violations whenever a fork() operation is used within Visual Threads. This patch fixes this problem. The strncasecmp() and strcasecmp() routines did not check the input parameters for NULL. Attempts to access the data through the NULL parameters resulted in seg faults. This patch fixes this problem by handling NULL parameters as special cases. The nacreate() routine in the libnuma library calls nmmap() and is supposed to return NULL if the call failed. The failure check was incorrectly coded and could result in a seg fault instead of the correct NULL return from nacreate(). This patch fixes the failure check from the nmmap() call in nacreate(), thus avoiding the potential seg fault.