The webdriver for the Browser object expects an error object to be initialized when the webdriver_session_query function fails. But this function can fail for various reasons without an error description and then the wd->error will be NULL and trying to read from it will result in a crash.
Credits
Zabbix wants to thank zhutyra for submitting this report on the HackerOne bug bounty platform.