Add changes necessary when enabling BLE MESH
I'm working on adding BLE mesh support and these changes are necessary, otherwise I get the following error:
This might be a bad attempt at optimizing strncpy so it doesn't copy over the end of the string (documentation says it overwrites the remaining length in the destination buffer with zeroes), either way we need to specify the correct length for the destination buffer to fix the issue.