bug#50070: chmod reads uninitialized variables when fts_info is an error and -v is set, leading to random error messages

2021-08-15 Thread Paul Eggert
Thanks for reporting the bug. I installed the attached patch to fix it. >From af4711d5dc15f0c014bfd9c92f4eadedb89f732f Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Sun, 15 Aug 2021 21:29:38 -0700 Subject: [PATCH] chmod: fix use of uninitialized var if -v Problem reported by Michael Debertol

bug#50070: chmod reads uninitialized variables when fts_info is an error and -v is set, leading to random error messages

2021-08-15 Thread Michael Debertol
Hi, I noticed that when running chmod with -v on a dangling symlink the error message is somewhat random: > ln -s file-that-does-not-exist lnk > chmod -w lnk -v > chmod: cannot operate on dangling symlink 'lnk' > failed to change mode of 'lnk' from (-) to (rwsrwsrwt) >