Re: [PATCH 10/11] ref_transaction_verify(): new function to check a reference's value

2015-02-11 Thread Michael Haggerty
On 02/09/2015 07:50 PM, Stefan Beller wrote: On Sun, Feb 8, 2015 at 8:14 AM, Michael Haggerty mhag...@alum.mit.edu wrote: /* - * Add a reference update to transaction. new_sha1 is the value that - * the reference should have after the update, or null_sha1 if it should - * be deleted. If

Re: [PATCH 10/11] ref_transaction_verify(): new function to check a reference's value

2015-02-09 Thread Stefan Beller
On Sun, Feb 8, 2015 at 8:14 AM, Michael Haggerty mhag...@alum.mit.edu wrote: /* - * Add a reference update to transaction. new_sha1 is the value that - * the reference should have after the update, or null_sha1 if it should - * be deleted. If old_sha1 is non-NULL, then it the value - *

[PATCH 10/11] ref_transaction_verify(): new function to check a reference's value

2015-02-08 Thread Michael Haggerty
If NULL is passed to ref_transaction_update()'s new_sha1 parameter, then just verify old_sha1 (under lock) without trying to change the new value of the reference. Use this functionality to add a new function ref_transaction_verify(), which checks the current value of the reference under lock but