Use strlcpy instead of a memset&strcpy combo. Guarantees \0-terminaltion and gives...