It seems the application that you are talking about does not have that much complexity, so having log-in in a same page works better, in case if security reasons are important for you, so second page would be recommended.
Yahoo and big sites like that have so many actions in their first page, so including the log-in action in those page can potentially brings usability issues, sometimes log-in input boxes may be mistaken as search area, or newsletter email submission boxes. Also error handling will be confusing and anyway they are forced to use a second page for error handling. That's why they should put that in a second level action. If you do not have too many components in the homepage, using drop-downs will work great. But you should still deal with the error messages. Maybe you need to have another log-in page in case if you got an error in the log-in process, or you can handle those email in homepage with nice AJAX implementations.
I don't know why you used Twitter as the example for the second option, Twitter has its log-in input right in the middle of its homepage, which is not a bad solution in case if the only important component that you have in the page is the log-in component. With this style you don't need to have another page for error handling.