]> granicus.if.org Git - sudo/commit
Minor snprintf() usage tweaks:
authorTodd C. Miller <Todd.Miller@sudo.ws>
Sun, 20 Jan 2019 14:49:48 +0000 (07:49 -0700)
committerTodd C. Miller <Todd.Miller@sudo.ws>
Sun, 20 Jan 2019 14:49:48 +0000 (07:49 -0700)
commit985600e7f03a24124032548f7088a445be6f09ec
treefce6e0d937af8d90ed5c061209780353e0f6fa64
parent3d63eee344df8d7a2023bd44d2c2244f3772067d
Minor snprintf() usage tweaks:
1) don't assume snprintf() returns -1 on error, check for <0
2) when comparing return value of sizeof(foo), cast the sizeof, not the len
3) cast return value to void in cases where snprintf cannot fail
26 files changed:
lib/util/regress/vsyslog/vsyslog_test.c
lib/util/sig2str.c
plugins/sudoers/alias.c
plugins/sudoers/cvtsudoers_pwutil.c
plugins/sudoers/env.c
plugins/sudoers/find_path.c
plugins/sudoers/fmtsudoers.c
plugins/sudoers/group_plugin.c
plugins/sudoers/iolog.c
plugins/sudoers/ldap.c
plugins/sudoers/ldap_conf.c
plugins/sudoers/ldap_util.c
plugins/sudoers/logging.c
plugins/sudoers/match.c
plugins/sudoers/parse.c
plugins/sudoers/set_perms.c
plugins/sudoers/starttime.c
plugins/sudoers/sudoers.c
plugins/sudoers/sudoreplay.c
plugins/sudoers/timestamp.c
plugins/sudoers/tsdump.c
src/exec_monitor.c
src/exec_nopty.c
src/exec_pty.c
src/sudo.c
src/ttyname.c