incorporate suggestions from cppcheck.
Make one-parameter constructors explicit. Pass parameters by const reference if copying is potentially expensive. Pass string instead of const char* to function that expects a string. Fix out-of-bounds access.
Edited by Bernd Flemisch