Use APPDATA for HOME equivalent
authorNIIBE Yutaka <gniibe@fsij.org>
Mon, 21 Jan 2013 03:09:33 +0000 (12:09 +0900)
committerNIIBE Yutaka <gniibe@fsij.org>
Mon, 21 Jan 2013 03:09:33 +0000 (12:09 +0900)
tool/gpg_agent.py

index 8a35ccb..46036d1 100644 (file)
@@ -7,6 +7,8 @@ class gpg_agent(object):
     def __init__(self):
         if IS_WINDOWS:
             home = os.getenv("HOME")
+            if not home:
+                home = os.getenv("APPDATA")
             comm_port = os.path.join(home, "gnupg", "S.gpg-agent")
             #
             f = open(comm_port, "rb", 0)