Fix a bug : localStorage in privacy option

Fix a bug that LocalStorage in privacy option can not catch the exception . My solution depends on http://stackoverflow.com/questions/14555347/html5-localstorage-error-with-safari-quota-exceeded-err-dom-exception-22-an