summaryrefslogtreecommitdiff
path: root/src/ls.c
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>1992-10-31 23:00:13 +0000
committerJim Meyering <jim@meyering.net>1992-10-31 23:00:13 +0000
commit52d8f3c425679de813a0e58530564668e364361d (patch)
tree29d36e0fd2d840f4b0287f58a3c3604da4b68b72 /src/ls.c
parent52cafd727f9c0616e7780f7deddaa29e6a443029 (diff)
downloadcoreutils-52d8f3c425679de813a0e58530564668e364361d.tar.xz
Add parentheses to expressions like (c = *p++) as per suggestion
from gcc -Wall.
Diffstat (limited to 'src/ls.c')
-rw-r--r--src/ls.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/ls.c b/src/ls.c
index 3f207274d..24343a695 100644
--- a/src/ls.c
+++ b/src/ls.c
@@ -783,7 +783,7 @@ print_dir (name, realname)
clear_files ();
- while (next = readdir (reading))
+ while ((next = readdir (reading)) != NULL)
if (file_interesting (next))
total_blocks += gobble_file (next->d_name, 0, name);
@@ -1429,7 +1429,7 @@ print_name_with_quoting (p)
if (quote_as_string)
putchar ('"');
- while (c = *p++)
+ while ((c = *p++))
{
if (quote_funny_chars)
{
@@ -1554,7 +1554,7 @@ length_of_file_name_and_frills (f)
if (quote_as_string)
len += 2;
- while (c = *p++)
+ while ((c = *p++))
{
if (quote_funny_chars)
{