summaryrefslogtreecommitdiffstats
path: root/text-utils/column.c
diff options
context:
space:
mode:
authorSami Kerola2011-09-10 16:48:12 +0200
committerSami Kerola2011-09-10 16:48:12 +0200
commit6a41edfa5bb215fb878d5f7e68951fe39c2ad515 (patch)
treed7ade2cf487f8d75019e7e687545ac1029fceb66 /text-utils/column.c
parentbuild-sys: ddate typo fixed (diff)
downloadkernel-qcow2-util-linux-6a41edfa5bb215fb878d5f7e68951fe39c2ad515.tar.gz
kernel-qcow2-util-linux-6a41edfa5bb215fb878d5f7e68951fe39c2ad515.tar.xz
kernel-qcow2-util-linux-6a41edfa5bb215fb878d5f7e68951fe39c2ad515.zip
column: fix error reported by smatch
column.c:201:2: error: 'for' loop initial declarations are only allowed in C99 mode Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Diffstat (limited to 'text-utils/column.c')
-rw-r--r--text-utils/column.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/text-utils/column.c b/text-utils/column.c
index 1e7a5779d..f8fd35071 100644
--- a/text-utils/column.c
+++ b/text-utils/column.c
@@ -106,6 +106,7 @@ int main(int argc, char **argv)
{
struct winsize win;
int ch, tflag = 0, xflag = 0;
+ int i;
long termwidth = 80;
int entries = 0; /* number of records */
unsigned int eval = 0; /* exit value */
@@ -198,7 +199,7 @@ int main(int argc, char **argv)
else
r_columnate(maxlength, termwidth, list, entries);
- for (int i = 0; i < entries; i++)
+ for (i = 0; i < entries; i++)
free(list[i]);
free(list);