fixed some typos and minor issues, including Red Hat issue 1021967

This commit is contained in:
Gerhard Rieger 2014-03-26 13:25:07 +01:00
parent fe0aed5156
commit df152fce75
4 changed files with 13 additions and 7 deletions

View file

@ -41,6 +41,9 @@ corrections:
Red Hat issue 1021972: fixed a missing NUL termination in return string
of sysutils.c:sockaddr_info() for the AF_UNIX case
fixed some typos and minor issues, including:
Red Hat issue 1021967: formatting error in manual page
fixed bug in xio-openssl.c that prevented error handling of bad number
of arguments, thanks to Paulik Tamas for reporting

2
README
View file

@ -190,7 +190,7 @@ platform specifics - hp-ux
--------------------------
Ancillary messages cannot be compiled in with socat: both struct msghdr and
strutc cmsghdr are required. Compiling with -D_XOPEN_SOURCE_EXTENDED provides
struct cmsghdr are required. Compiling with -D_XOPEN_SOURCE_EXTENDED provides
struct msghdr but disables struct cmsghdr while -D_OPEN_SOURCE disables struct
msghdr but disables struct cmsghdr. Please contact socat development if you
know a solution.

View file

@ -45,6 +45,9 @@ _MICROS=$((MICROS+999999)); SECONDs="${_MICROS%??????}"
withroot=0 # perform privileged tests even if not run by root
#PATH=$PATH:/opt/freeware/bin
#PATH=$PATH:/usr/local/ssl/bin
case "$0" in
*/*) PATH="${0%/*}:$PATH"
esac
#OPENSSL_RAND="-rand /dev/egd-pool"
#SOCAT_EGD="egd=/dev/egd-pool"
MISCDELAY=1
@ -236,7 +239,7 @@ ECHO="echo $E"
PRINTF="printf"
case "$TERM" in
vt100|vt320|linux|xterm|cons25|dtterm|aixterm|sun-color|xterm-color)
vt100|vt320|linux|xterm|cons25|dtterm|aixterm|sun-color|xterm-color|xterm-256color)
# there are different behaviours of printf (and echo)
# on some systems, echo behaves different than printf...
if [ $($PRINTF "\0101") = "A" ]; then

View file

@ -1172,14 +1172,14 @@ void xiosigaction_hasread(int signum
if (pid == 0) {
Msg(wassig?E_INFO:E_WARN,
"waitpid(-1, {}, WNOHANG): no child has exited");
Info("childdied() finished");
Info("xiosigaction_hasread() finished");
errno = _errno;
Debug("xiosigaction_hasread() ->");
return;
} else if (pid < 0 && errno == ECHILD) {
Msg1(wassig?E_INFO:E_WARN,
"waitpid(-1, {}, WNOHANG): %s", strerror(errno));
Info("childdied() finished");
Info("xiosigaction_hasread() finished");
errno = _errno;
Debug("xiosigaction_hasread() ->");
return;
@ -1187,7 +1187,7 @@ void xiosigaction_hasread(int signum
wassig = true;
if (pid < 0) {
Warn2("waitpid(-1, {%d}, WNOHANG): %s", status, strerror(errno));
Info("childdied() finished");
Info("xiosigaction_hasread() finished");
errno = _errno;
Debug("xiosigaction_hasread() ->");
return;
@ -1815,7 +1815,7 @@ int xiocheckpeer(xiosingle_t *xfd,
#if WITH_IP6
if (pa->soa.sa_family == AF_INET6 &&
ntohs(((struct sockaddr_in6 *)pa)->sin6_port) != xfd->para.socket.ip.sourceport) {
Warn1("refusing connection from %s due to sourceport option",
Warn1("refusing connection from %s due to wrong sourceport",
sockaddr_info((struct sockaddr *)pa, 0,
infobuff, sizeof(infobuff)));
return -1;
@ -2163,7 +2163,7 @@ int xiosetsockaddrenv(const char *lr,
/* these do sockets internally */
/* retrieves options so-type and so-prototype from opts, calls socketpair, and
/* retrieves options so-type and so-prototype from opts, calls socket, and
ev. generates an appropriate error message.
returns 0 on success or -1 if an error occurred. */
int