mirror of
https://github.com/vivier/EMILE.git
synced 2024-10-31 20:05:01 +00:00
9bd9755dbb
Signed-off-by: Laurent Vivier <Laurent@Vivier.EU>
27 lines
366 B
C
27 lines
366 B
C
/*
|
|
*
|
|
* (c) 2004,2005 Laurent Vivier <Laurent@Vivier.EU>
|
|
*
|
|
*/
|
|
|
|
#include <string.h>
|
|
#include <sys/types.h>
|
|
|
|
#include <macos/devices.h>
|
|
|
|
OSErr CloseDriver(short refNum)
|
|
{
|
|
OSErr err;
|
|
ParamBlockRec param;
|
|
|
|
memset(¶m, 0, sizeof(ParamBlockRec));
|
|
|
|
param.ioRefNum = refNum;
|
|
|
|
err = PBCloseSync(¶m);
|
|
if (err != noErr)
|
|
return err;
|
|
|
|
return param.ioResult;
|
|
}
|