Renaming local.h to local.hpp
Fixes for C++11
Adding safety checks to HTTP request handler