make compile with -Wall -Wextra -pedantic -Werror
use strncpy and snprintf in Error.cpp
snprintf for MSVC