Ethics of Self-driving cars

Well I just read something pretty disturbing that GM for 10 years basically hid the fact that the ignition system was faulty and can cause the car to stall, leaving the passengers with no airbags. (http://finance.yahoo.com/news/engineers-switch-hell-began-gm-recall-woes-071538074–finance.html)

Ethically how are selfdriving/autonomous cars and the software in them going to do better?  It is already known that bugs are essentially inherent to software.  Will we rely on transparency of software? Who will be responsible?  There will probably be many people working on the bad piece of code.  These are questions that I think I should take the time to answer.