aboutsummaryrefslogtreecommitdiff
path: root/src/librc-misc.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/librc-misc.c')
-rw-r--r--src/librc-misc.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/librc-misc.c b/src/librc-misc.c
index fcb536f2..b367ccc3 100644
--- a/src/librc-misc.c
+++ b/src/librc-misc.c
@@ -447,7 +447,10 @@ char **rc_get_list (char **list, const char *file)
token = strsep (&p, "#");
if (token && (strlen (token) > 1))
{
- token[strlen (token) - 1] = 0;
+ /* Stip the newline if present */
+ if (token[strlen (token) - 1] == '\n')
+ token[strlen (token) - 1] = 0;
+
list = rc_strlist_add (list, token);
}
}
@@ -745,9 +748,5 @@ char **rc_config_env (char **env)
free (line);
}
- /* Set this var to ensure that things are POSIX, which makes scripts work
- on non GNU systems with less effort. */
- env = rc_strlist_add (env, "POSIXLY_CORRECT=1");
-
return (env);
}