Commit 9e37125a authored by A. Jesse Jiryu Davis's avatar A. Jesse Jiryu Davis
Browse files

CDRIVER-979 bson_strncpy aborts on windows

On platforms where bson_strncpy can call strncpy, if the destination is too
small to copy the whole string, bson_strncpy truncates it to fit. On Windows it
calls strcpy_s, which aborts the program if the source string is too long.

On Windows bson_strncpy should call strncpy_s (with an "n") instead, which
accepts a "_TRUNCATE" option that behaves like standard strncpy.
parent 76796b76
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment