Merge branch 'mg/lib-gpg-ro-safety'
authorJunio C Hamano <gitster@pobox.com>
Wed, 29 Oct 2014 17:08:15 +0000 (10:08 -0700)
committerJunio C Hamano <gitster@pobox.com>
Wed, 29 Oct 2014 17:08:16 +0000 (10:08 -0700)
In a tarball extract whose files are all read-only, running GPG
tests would have failed due to unwritable files.

* mg/lib-gpg-ro-safety:
t/lib-gpg: make gpghome files writable

1  2 
t/lib-gpg.sh
diff --combined t/lib-gpg.sh
index fd499e7c498449834992e67645f098d49c6290b8,fc5ca99046ee2cd7e126c0c1aeb1455d7bb4e29f..cd2baef383df7dbea5b1544a162f99573476520e
@@@ -1,6 -1,6 +1,6 @@@
  #!/bin/sh
  
 -gpg_version=`gpg --version 2>&1`
 +gpg_version=$(gpg --version 2>&1)
  if test $? = 127; then
        say "You do not seem to have gpg installed"
  else
@@@ -18,6 -18,7 +18,7 @@@
                # No password given, to enable non-interactive operation.
                cp -R "$TEST_DIRECTORY"/lib-gpg ./gpghome
                chmod 0700 gpghome
+               chmod 0600 gpghome/*
                GNUPGHOME="$(pwd)/gpghome"
                export GNUPGHOME
                test_set_prereq GPG