From c6394074a8f80fe2879195eab6a275dad39c1789 Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Fri, 10 Nov 1995 14:54:08 +0000 Subject: [PATCH] (parse_ls_color): Use strcpy to initialize 3-character array. Automatic aggregate initialization isn't portable. --- src/ls.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/ls.c b/src/ls.c index dd42e0b60c..e07c0eaa9d 100644 --- a/src/ls.c +++ b/src/ls.c @@ -1059,8 +1059,9 @@ parse_ls_color (void) int ind_no; /* Indicator number */ int ccount; /* Character count */ int num; /* Escape char numeral */ - char label[3] = "??"; /* Indicator label */ + char label[3]; /* Indicator label */ + strcpy (label, "??"); if ((p = getenv (whichvar = "LS_COLORS")) || (p = getenv (whichvar = "LS_COLOURS"))) { -- 2.47.3