Use string::copy rather than memcpy

This commit is contained in:
Max Brunsfeld 2017-08-01 10:26:42 -07:00
parent ccc07eab4b
commit 8f67869b16
1 changed files with 1 additions and 1 deletions

2
src/scanner.cc vendored
View File

@ -28,7 +28,7 @@ struct Scanner {
}
unsigned serialize(char *buffer) {
memcpy(buffer, heredoc_delimiter.c_str(), heredoc_delimiter.length());
heredoc_delimiter.copy(buffer, heredoc_delimiter.length());
return heredoc_delimiter.length();
}