If the application provides an output buffer for the constructed
connection string, the driver will currently return an error and thus
fail the connection. The correct handling is however to apply truncation
but return the number of characters available without truncation.
This PR works around swprintf() returning an error code, but
otherwise correctly 0-terminating the destination buffer and not setting
the errno.
If the application provides an output buffer for the constructed connection string, the driver will currently return an error and thus fail the connection. The correct handling is however to apply truncation but return the number of characters available without truncation.
This PR works around swprintf() returning an error code, but otherwise correctly 0-terminating the destination buffer and not setting the errno.