Strcpy/strncpy fixes, warnings.

Fix strcpy/strncpy return value, enable warnings during compilation and fix a
couple of minor issues.