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
This commit is contained in:
Junio C Hamano
2017-04-23 22:07:51 -07:00
5 changed files with 49 additions and 1 deletions

6
refs.c
View File

@ -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);
}