]> git.baikalelectronics.ru Git - kernel.git/commit
[media] dvb-bt8xx: use goto based exception handling
authorJonathan Nieder <jrnieder@gmail.com>
Sat, 31 Dec 2011 10:58:34 +0000 (07:58 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Fri, 6 Jan 2012 14:43:34 +0000 (12:43 -0200)
commit1b7e52599727ce267ee4447c503a5cd3c2839fac
tree0bc9c094d1382ed0f760f407c77f6cb552741f5c
parent9b1a67539d66cd130d6574198308513022aa10d4
[media] dvb-bt8xx: use goto based exception handling

Repeating the same cleanup code in each error handling path makes life
unnecessarily difficult for reviewers, who much check each instance of
the same copy+pasted code separately.  A "goto" to the end of the
function is more maintainable and conveys the intent more clearly.

While we're touching this code, also lift some assignments from "if"
conditionals for simplicity.

No functional change intended.

Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/dvb/bt8xx/dvb-bt8xx.c