Driver should operate cookies for the current frame, not the topmost one. Fixes issue 7799 in Firefox
WDBS: safe check for window.localStorage

Sometimes access to window.localStorage property is prohibited, so the check should be wrapped into try/catch.
Fixes regression introduced in 80ccbb8 and 2262635
Fix a typo
On behalf of velma911: Fixing infinite read from socket. Fixes issue 7814
Log formatter should be able to work with empty keys array. Fixes issue 7357

Signed-off-by: Alexei Barantsev <barancev@gmail.com>
Merge pull request #1 from SeleniumHQ/master

resync with master