1 /* $Id: win32err.c 16861 2005-07-29 13:46:03Z ea $
5 * Copyright (c) 1998 Mark Russinovich
7 * http://www.sysinternals.com/
9 * --------------------------------------------------------------------
11 * This software is free software; you can redistribute it and/or
12 * modify it under the terms of the GNU Library General Public License as
13 * published by the Free Software Foundation; either version 2 of the
14 * License, or (at your option) any later version.
16 * This software is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19 * Library General Public License for more details.
21 * You should have received a copy of the GNU Library General Public
22 * License along with this software; see the file COPYING.LIB. If
23 * not, write to the Free Software Foundation, Inc., 675 Mass Ave,
24 * Cambridge, MA 02139, USA.
26 * --------------------------------------------------------------------
28 * Print a Win32 error.
30 * 1999 February (Emanuele Aliberti)
31 * Taken from chkdskx.c and formatx.c by Mark Russinovich
32 * to be used in all sysutils.
37 //----------------------------------------------------------------------
41 // Takes the win32 error code and prints the text version.
43 //----------------------------------------------------------------------
53 (FORMAT_MESSAGE_ALLOCATE_BUFFER
| FORMAT_MESSAGE_FROM_SYSTEM
),
56 MAKELANGID(LANG_NEUTRAL
, SUBLANG_DEFAULT
),
66 LocalFree( lpMsgBuf
);