stralign_s.h 824 B

12345678910111213141516171819202122232425262728293031
  1. /**
  2. * This file has no copyright assigned and is placed in the Public Domain.
  3. * This file is part of the w64 mingw-runtime package.
  4. * No warranty is given; refer to the file DISCLAIMER within this package.
  5. */
  6. #ifndef __STRALIGN_H_S_
  7. #define __STRALIGN_H_S_
  8. #include <stralign.h>
  9. #if defined(MINGW_HAS_SECURE_API)
  10. #ifdef __cplusplus
  11. extern "C" {
  12. #endif
  13. #if !defined(I_X86_) && defined(_WSTRING_S_DEFINED)
  14. #if defined(__cplusplus) && defined(_WConst_Return)
  15. static __inline PUWSTR ua_wcscpy_s(PUWSTR Destination,size_t DestinationSize,PCUWSTR Source) {
  16. if(WSTR_ALIGNED(Source) && WSTR_ALIGNED(Destination)) return (wcscpy_s((PWSTR)Destination,DestinationSize,(PCWSTR)Source)==0 ? Destination : NULL);
  17. return uaw_wcscpy((PCUWSTR)String,Character);
  18. }
  19. #endif
  20. #endif
  21. #ifdef __cplusplus
  22. }
  23. #endif
  24. #endif
  25. #endif