diff options
author | Junio C Hamano <gitster@pobox.com> | 2017-04-23 22:07:51 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2017-04-23 22:07:52 -0700 |
commit | 9f1384f711e4d04d7808d4e24860b17f656b7333 (patch) | |
tree | 05c3fabffdb57078460b3c89b6df3ae5c473c18f /refs.c | |
parent | d7f8a37852fe26df530327b4131c92b2058ecd08 (diff) | |
parent | d8f4481c4f03132174b514f428cd67d2cc0dc997 (diff) | |
download | git-9f1384f711e4d04d7808d4e24860b17f656b7333.tar.gz git-9f1384f711e4d04d7808d4e24860b17f656b7333.tar.xz |
Merge branch 'jk/quarantine-received-objects'
Add finishing touches to a recent topic.
* jk/quarantine-received-objects:
refs: reject ref updates while GIT_QUARANTINE_PATH is set
receive-pack: document user-visible quarantine effects
receive-pack: drop tmp_objdir_env from run_update_hook
Diffstat (limited to 'refs.c')
-rw-r--r-- | refs.c | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -1643,6 +1643,12 @@ int ref_transaction_commit(struct ref_transaction *transaction, { struct ref_store *refs = transaction->ref_store; + if (getenv(GIT_QUARANTINE_ENVIRONMENT)) { + strbuf_addstr(err, + _("ref updates forbidden inside quarantine environment")); + return -1; + } + return refs->be->transaction_commit(refs, transaction, err); } |