Add (void) cast in front of rmtree() call at the end of pg_upgrade

Most calls of rmtree() report an error, and the code coming from 38bfae3
has introduced one caller where this is not done.  The previous behavior
was to not fail hard if any log file generated is not properly unlinked
when cleaning up the contents generated once the upgrade has completed,
so add a cast to (void) to indicate the intention behind this new code.

Per gripe from Coverity.
This commit is contained in:
Michael Paquier 2022-02-07 14:19:52 +09:00
parent 38bfae3652
commit 42a9e88bf6
1 changed files with 1 additions and 1 deletions

View File

@ -754,5 +754,5 @@ cleanup(void)
/* Remove dump and log files? */
if (!log_opts.retain)
rmtree(log_opts.basedir, true);
(void) rmtree(log_opts.basedir, true);
}