Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 4 additions & 6 deletions platform/native/lui_webapp/test/lui_webapp_test.ml
Original file line number Diff line number Diff line change
Expand Up @@ -376,13 +376,11 @@ let test_boot_fallback () =

let cli_exe () = Filename.dirname Sys.executable_name / ".." / "main.exe"

(* Spawn the launcher directly: no [sh -c] indirection, whose quoting
and path translation of a native Windows path is shell-dependent
(a fresh Cygwin sh exits 127 on it). *)
let run_cli args =
let cmd =
List.fold_left
(fun acc a -> acc ^ " " ^ Filename.quote a)
(Filename.quote (cli_exe ())) args
in
let r = P.Proc.run "sh" [ "-c"; cmd ] in
let r = P.Proc.run (cli_exe ()) args in
(r.P.Proc.status, String.trim (r.P.Proc.stdout ^ r.P.Proc.stderr))

let test_cli_errors () =
Expand Down
6 changes: 6 additions & 0 deletions platform/native/lui_webview/lui_webview_stubs.m
Original file line number Diff line number Diff line change
Expand Up @@ -1025,6 +1025,12 @@ extern __declspec(dllimport) long LUI_STDCALL GetHGlobalFromStream(
extern __declspec(dllimport) long LUI_STDCALL CreateStreamOnHGlobal(
void *, int, void **);
extern __declspec(dllimport) void LUI_STDCALL CoTaskMemFree(void *);
#else
/* <windows.h> came in via SDL_syswm.h, which defines
WIN32_LEAN_AND_MEAN: that skips the COM headers, so the real
CoTaskMemFree / CreateStreamOnHGlobal / GetHGlobalFromStream protos
must be pulled in explicitly. */
#include <objbase.h>
#endif /* !WINAPI — no real Win32 headers in this TU */

typedef struct {
Expand Down
Loading