More checks for string copies

Remove also some warnings compiling code.

Signed-off-by: Frediano Ziglio <freddy77@gmail.com>
Check string copy on server source

Signed-off-by: Frediano Ziglio <freddy77@gmail.com>