core/emperor: check return value of uwsgi_stats_str

Reported by Coverity as CID #970959
core/static: check return value of uwsgi_response_prepare_headers

Reported by Coverity as CID #970965
plugins/http: check return value of uwsgi_cr_set_hooks

Reported by Coverity as CID #970970
plugins/sslrouter: check return value of uwsgi_cr_set_hooks

Reported by Coverity as CID #971229
plugins/php: check return value of uwsgi_response_prepare_headers

Reported by Coverity as CID #1100794
plugins/lua: check return value of uwsgi_response_prepare_headers

Reported by Coverity as CID #1100802
Merge pull request #497 from xrmx/coverity2812

More coverity fixes
fixed lua prepare_headers