win_util.h 569 B

1234567891011121314151617181920212223
  1. /*
  2. * Copyright (C) 2023 Amazon Inc. All rights reserved.
  3. * SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
  4. */
  5. #ifndef _WIN_UTIL_H
  6. #define _WIN_UTIL_H
  7. #include "platform_wasi_types.h"
  8. #include "windows.h"
  9. __wasi_timestamp_t
  10. convert_filetime_to_wasi_timestamp(LPFILETIME filetime);
  11. /* Convert a Windows error code to a WASI error code */
  12. __wasi_errno_t
  13. convert_windows_error_code(DWORD windows_error_code);
  14. /* Convert a Winsock error code to a WASI error code */
  15. __wasi_errno_t
  16. convert_winsock_error_code(int error_code);
  17. #endif /* end of _WIN_UTIL_H */