From 4cebaf45e4b1a5edc30ee8a3a5bc2483cf7e9563 Mon Sep 17 00:00:00 2001 From: Gerhard Rieger Date: Sun, 24 Oct 2021 09:39:35 +0200 Subject: [PATCH] Some minor non functional corrections --- CHANGES | 8 ++++++-- test.sh | 4 ++-- vsnprintf_r.c | 2 +- 3 files changed, 9 insertions(+), 5 deletions(-) diff --git a/CHANGES b/CHANGES index bd86f57..984d391 100644 --- a/CHANGES +++ b/CHANGES @@ -67,6 +67,9 @@ Documentation: Added missing closing parenthesis in socat.yo. Thanks to Emanuele Torre for reporting this issue. + Corrected more typos and added missing bug info to CHANGES, performed + some non functional corrections + ####################### V 1.7.4.1: Corrections: @@ -135,6 +138,7 @@ Corrections: packet. The fix makes RECVFROM drop the packet when the second address failed before reading it. Use retry or forever option with the second address if you want to avoid data loss. + Fixes Red Hat bug 1907718 Thanks to Chunmei Xu for reporting this issue and proving the patch. Socats DTLS implementation has been reworked and appears to work now @@ -179,7 +183,7 @@ Porting: ai_protocol=0 and try again Test: SCTP_SERVICENAME - Per file filesystem options were still name ext2-* and depended on + Per file filesystem options were still named ext2-* and depended on . Now they are called fs-* and depend on . These fs-* options are also available on old systems with ext2_fs.h @@ -384,7 +388,7 @@ Corrections: Print a useful error message when single character options appear to be merged in Socat invocation - Test: SOCCAT_OPT_HINT + Test: SOCAT_OPT_HINT Fixed some docu typos. Thanks to Travis Wellman, Thomas , Dan Kenigsberg, diff --git a/test.sh b/test.sh index 9fd3f34..ac74f16 100755 --- a/test.sh +++ b/test.sh @@ -5379,7 +5379,7 @@ mkfifo "$tpi" touch "$tpo" # # during development of this test, the following command line succeeded: -# (sleep 1; $ECHO "user\n\c"; sleep 1; $ECHO "password\c"; sleep 1; $ECHO "\n\c"; sleep 1; $ECHO "test 1\n\c"; sleep 1; $ECHO "\003\c"; sleep 1; $ECHO "test 2\n\c"; sleep 1; $ECHO "exit\n\c"; sleep 1) |$TRACE $SOCAT -d -d -d -d -lf/tmp/gerhard/debug1 -v -x - exec:'./readline.sh ./readline-test.sh',pty,ctty,setsid,raw,echo=0,isig +# (sleep 1; $ECHO "user\n\c"; sleep 1; $ECHO "password\c"; sleep 1; $ECHO "\n\c"; sleep 1; $ECHO "test 1\n\c"; sleep 1; $ECHO "\003\c"; sleep 1; $ECHO "test 2\n\c"; sleep 1; $ECHO "exit\n\c"; sleep 1) |$TRACE $SOCAT -d -d -d -d -lf/tmp/$USER/debug1 -v -x - exec:'./readline.sh ./readline-test.sh',pty,ctty,setsid,raw,echo=0,isig # PATH=${SOCAT%socat}:$PATH eval "$CMD 2>$te &" pid=$! # background process id @@ -13925,7 +13925,7 @@ CMD="$TRACE $SOCAT $opts - $tf,o-direct,ignoreeof!!$tf" echo "$da" |$CMD >"$to" 2>"$te" rc=$? if [ $rc -ne 0 ] && grep -q "Invalid argument" "$te" && [ $UNAME = Linux ]; then - case $(stat -f /tmp/gerhard/ |grep -o "Type: [^[:space:]]*" |cut -c 7-) in + case $(stat -f $tf |grep -o "Type: [^[:space:]]*" |cut -c 7-) in ext2/ext3|xfs|reiserfs) $PRINTF "${FAILED}\n" echo "$CMD" >&2 diff --git a/vsnprintf_r.c b/vsnprintf_r.c index eaa610f..fe8a966 100644 --- a/vsnprintf_r.c +++ b/vsnprintf_r.c @@ -374,7 +374,7 @@ int vsnprintf_r(char *str, size_t size, const char *format, va_list ap) { #if HAVE_TYPE_LONGLONG # define num_buff_len ((sizeof(unsigned long long)*8+2)/3+1) /* hold up to u long long in octal w/ \0 */ #else -# define num_buff_len ((sizeof(unsigned long)*8+2)/3+1)]; /* hold up to u long in octal w/ \0 */ +# define num_buff_len ((sizeof(unsigned long)*8+2)/3+1) /* hold up to u long in octal w/ \0 */ #endif char lengthmod = '\0'; /* 'h' 'l' 'L' 'z' */ int leading0 = 0; /* or 1 */