[Patch 3/4] chunkd: make error paths more regular

2009-12-25 Thread Pete Zaitcev
1. Don't try to save a call in a function where normal and error unfolding sequences are different. 2. Use exception labels linked to what caused them, not to what cleanup has to be done. 3. Balance fs_open - fs_close. Signed-off-by: Pete Zaitcev zait...@redhat.com --- server/be-fs.c |

Re: [Patch 3/4] chunkd: make error paths more regular

2009-12-25 Thread Jeff Garzik
On 12/26/2009 01:34 AM, Pete Zaitcev wrote: diff --git a/server/be-fs.c b/server/be-fs.c index 89635f8..6551c83 100644 --- a/server/be-fs.c +++ b/server/be-fs.c @@ -75,7 +75,7 @@ int fs_open(void) } if (!tchdbsetmutex(hdb)) - goto out_hdb; + goto