nmh-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nmh-commits] [SCM] The nmh Mail Handling System branch, master, updated


From: Ralph Corderoy
Subject: [nmh-commits] [SCM] The nmh Mail Handling System branch, master, updated. 1.7-branchpoint-735-g5a163d2
Date: Sun, 23 May 2021 07:34:19 -0400 (EDT)

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "The nmh Mail Handling System".

The branch, master has been updated
       via  5a163d2728b4728cf4a2e0a69d992c37c0252f99 (commit)
       via  2df6d33755f4a4f45b86fe4833fa3a7afbd88458 (commit)
       via  f83b1c70af771d59702d37fe2cf054c9f8840ff3 (commit)
       via  0468e7d78c7a6b218594762b935f8b00675bed39 (commit)
      from  1fc5243df618f327b8d15ace5b393a3874b76d13 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 5a163d2728b4728cf4a2e0a69d992c37c0252f99
Author: Ralph Corderoy <ralph@inputplus.co.uk>
Date:   Sun May 23 12:27:32 2021 +0100

    uip/flist.c: hush compiler by using int for precision specifier.
    
    size_ts were used for tracking the length of strings and the maximum
    seen, but printf(3)'s ‘*’ precision-specifier requires an int.
    Instead of adding a cast, assign strlen(3)'s size_t return value to an
    int as it's unlikely a folder or sequence name will ever exceed INT_MAX.
    Also, using ‘i = strnlen(s, INT_MAX)’ in addition would just confuse.

commit 2df6d33755f4a4f45b86fe4833fa3a7afbd88458
Author: Ralph Corderoy <ralph@inputplus.co.uk>
Date:   Sun May 23 12:16:24 2021 +0100

    uip/flist.c: don't copy folder name just to tack a ‘+’ on the end.
    
    Instead, print the ‘+’ or ‘ ’ as a separate ‘%c’ format 
specifier.
    Avoids a TRUNCCPY() or snprintf() to a fixed-size buffer.

commit f83b1c70af771d59702d37fe2cf054c9f8840ff3
Author: Ralph Corderoy <ralph@inputplus.co.uk>
Date:   Sun May 23 11:55:26 2021 +0100

    uip/mhfixmsg.c: hush compiler by enlarging snprintf() destination.
    
    Alter the destination array's definition to use sizeof on a string
    constant which shows the maximum which could be produced.  Don't use
    stdint.h's SIZE_MAX in the string as that comes with extra noise like
    a trailing ‘UL’ and parenthesis.
    
    A size_t is being printed so use ‘%zu’ rather than cast to unsigned.

commit 0468e7d78c7a6b218594762b935f8b00675bed39
Author: Ralph Corderoy <ralph@inputplus.co.uk>
Date:   Sun May 23 11:26:44 2021 +0100

    sbr/netsec.c: hush compiler by replacing fprintf() with fwrite().
    
    A printf(3) precision-specifier of ‘*’ takes an int but an unsigned was
    being passed.  Given the intent of ‘"%.*s\n", outlen, snoopoutbuf’ was
    to write outlen bytes of snoopoutbuf and a linefeed, replace it with an
    fwrite() and putc().  Examining the code shows no NUL is expected in
    snoopoutbuf within its first outlen bytes so using ‘%s’ is a bit
    misleading in isolation to the reader and makes more work for stdio.

-----------------------------------------------------------------------

Summary of changes:
 sbr/netsec.c   |  3 ++-
 uip/flist.c    | 18 +++++++-----------
 uip/mhfixmsg.c |  4 ++--
 3 files changed, 11 insertions(+), 14 deletions(-)


hooks/post-receive
-- 
The nmh Mail Handling System



reply via email to

[Prev in Thread] Current Thread [Next in Thread]