Merge pull request #74 from Qingtao-Cao/devel

Impose stricter control on requested URI on both server and client side
Postpone imposing stringent control on requested URI from clients

Revert to previous behaviour to only check if the requested URI
does not start with a slash at all, or started with double slashes
(possibly as a result of websever configuration error), until an
agreement can be reached regarding what kinds of requested URIs
are allowable.
Fixup a logic error in assembling MSBs' kWh readings in bms_adaptor

Now that we have avoided pointer casting in get_mtr_reading() such as

	*(uint16_t *)val += mtr->value.u16;

and replaced it with memcpy as below:

	memcpy(val, (void *)&mtr->value.u16, sizeof(uint16_t));

So as to avoid GCC strict-aliasing warning. This is a good thing to do,
however, there is a logic inconsistency that in the original approach
the *val would be an accumulation of any existing values plus the new
value read, however, in the latest approach it is simply replaced with
the latter.

To cope with this, the user should store any existing value and do
addition by themselves.

Lastly fix up whitespace errors in the lines of "break;", 2 tabs are
preferred to 8 consecutive white spaces.