summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBram Moolenaar <bram@vim.org>2012-02-29 13:49:09 +0100
committerBram Moolenaar <bram@vim.org>2012-02-29 13:49:09 +0100
commit281badd13fc23c7d632137188f8d77f72a8cdeb9 (patch)
tree86536d2023471ec0203e25ab087380c5580e4a0a
parent042c43603abc06b84b097bd70448706ba6c6ff2d (diff)
downloadvim-281badd13fc23c7d632137188f8d77f72a8cdeb9.tar.gz
updated for version 7.3.457v7.3.457v7-3-457
Problem: When setting $VIMRUNTIME later the directory for fetching translated messages is not adjusted. Solution: Put bindtextdomain() in vim_setenv().
-rw-r--r--src/misc1.c27
-rw-r--r--src/version.c2
2 files changed, 18 insertions, 11 deletions
diff --git a/src/misc1.c b/src/misc1.c
index 1945d0ac..cc292390 100644
--- a/src/misc1.c
+++ b/src/misc1.c
@@ -4133,17 +4133,6 @@ vim_getenv(name, mustfree)
{
vim_setenv((char_u *)"VIMRUNTIME", p);
didset_vimruntime = TRUE;
-#ifdef FEAT_GETTEXT
- {
- char_u *buf = concat_str(p, (char_u *)"/lang");
-
- if (buf != NULL)
- {
- bindtextdomain(VIMPACKAGE, (char *)buf);
- vim_free(buf);
- }
- }
-#endif
}
else
{
@@ -4221,6 +4210,22 @@ vim_setenv(name, val)
putenv((char *)envbuf);
}
#endif
+#ifdef FEAT_GETTEXT
+ /*
+ * When setting $VIMRUNTIME adjust the directory to find message
+ * translations to $VIMRUNTIME/lang.
+ */
+ if (*val != NUL && STRICMP(name, "VIMRUNTIME") == 0)
+ {
+ char_u *buf = concat_str(val, (char_u *)"/lang");
+
+ if (buf != NULL)
+ {
+ bindtextdomain(VIMPACKAGE, (char *)buf);
+ vim_free(buf);
+ }
+ }
+#endif
}
#if defined(FEAT_CMDL_COMPL) || defined(PROTO)
diff --git a/src/version.c b/src/version.c
index f47e7bd1..83965f44 100644
--- a/src/version.c
+++ b/src/version.c
@@ -715,6 +715,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 457,
+/**/
456,
/**/
455,