From 6680a2b30fe1fa2603056f92eeaa4865f6c1c299 Mon Sep 17 00:00:00 2001 From: Matthew Flatt Date: Fri, 1 Jul 2011 10:34:43 -0600 Subject: [PATCH] add ffi/winapi; use it in mzlib/os Closes PR 12007 original commit: 59731368fc7d90c1177c60ade3ec1f8c4fb0a4ae --- collects/mzlib/os.rkt | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/collects/mzlib/os.rkt b/collects/mzlib/os.rkt index 0d76602..98f0c9b 100644 --- a/collects/mzlib/os.rkt +++ b/collects/mzlib/os.rkt @@ -1,6 +1,9 @@ #lang mzscheme -(require mzlib/etc mzlib/foreign) (unsafe!) +(require mzlib/etc + ffi/unsafe + ffi/cvector + ffi/winapi) (define kernel32 (delay (and (eq? 'windows (system-type)) (ffi-lib "kernel32")))) @@ -23,7 +26,7 @@ (define windows-getcomputername (delay-ffi-obj "GetComputerNameExA" (force kernel32) - (_fun #:abi 'stdcall _int _bytes _cvector -> _int))) + (_fun #:abi winapi _int _bytes _cvector -> _int))) (define (gethostname) (case (system-type)