Merge pull request #2403 from facebook/no_strncpy

fix gcc10 warnings