Issue #9979: Use PyUnicode_AsWideCharString() in _ctypes module

 * Convert unicode to wide character string before creating the PyCapsule
   object
 * Catch integer overflow
 * Avoid useless memset()
 * Prepare the support of surrogates
2 files changed