diff options
author | BuildTools | 2015-09-22 11:39:57 -0700 |
---|---|---|
committer | BuildTools | 2015-09-22 11:39:57 -0700 |
commit | b433dbfb3e53e3f968d651acfbd436c7043f3de3 (patch) | |
tree | d24e65745f91b65901a74b50e792f7f7e63c4b73 /0005-w32-home.all.patch | |
download | aur-b433dbfb3e53e3f968d651acfbd436c7043f3de3.tar.gz |
init
Diffstat (limited to '0005-w32-home.all.patch')
-rw-r--r-- | 0005-w32-home.all.patch | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/0005-w32-home.all.patch b/0005-w32-home.all.patch new file mode 100644 index 000000000000..588997f63cb6 --- /dev/null +++ b/0005-w32-home.all.patch @@ -0,0 +1,24 @@ +--- aspell-0.60.7-20110707/common/config.cpp.orig 2014-03-20 19:51:08.756753700 +0000 ++++ aspell-0.60.7-20110707/common/config.cpp 2014-03-20 20:15:54.984480600 +0000 +@@ -664,6 +664,21 @@ + } else { // sep == '|' + assert(replace[0] == '$'); + const char * env = getenv(replace.c_str()+1); ++ if (NULL == env && strcmp (replace.c_str() + 1, "HOME") == 0) ++ { ++ const char *hd, *hp; ++ hd = getenv("HOMEDRIVE"); ++ hp = getenv("HOMEPATH"); ++ if (hd && hp) ++ { ++ char tmpbuf[strlen ("HOME=") + strlen (hd) + strlen (hp) + 1]; ++ strcpy (tmpbuf, "HOME="); ++ strcpy (&tmpbuf[strlen ("HOME=")], hd); ++ strcpy (&tmpbuf[strlen ("HOME=") + strlen (hd)], hp); ++ putenv (tmpbuf); ++ env = getenv(replace.c_str()+1); ++ } ++ } + final_str += env ? env : second; + } + replace = ""; |