[FIX] http dispatch: make sure transaction rollback happens in all cases when request...
authorOlivier Dony <odo@openerp.com>
Mon, 17 Mar 2014 16:32:28 +0000 (17:32 +0100)
committerOlivier Dony <odo@openerp.com>
Mon, 17 Mar 2014 16:32:28 +0000 (17:32 +0100)
commitf0d4240082fd2dd9ad109bfd7e3caead27410aa3
treee86a0d6fbf3b35aad74383782daf7be300f2966b
parent4c5d238191de3bdd65078966e54885a37bead415
[FIX] http dispatch: make sure transaction rollback happens in all cases when request handling raised (to be refactored)

Not doing so leads to cases where a transaction is committed
even after failing to validate a Python constraint.
This patch attempts to keep the rollback() logic next to the
corresponding commit(), and makes the rollback() more
explicit even if close() without commit() would also rollback
implicitly.

bzr revid: odo@openerp.com-20140317163228-zqbce8f0rgcg0pt4
openerp/http.py