1 /* registry.h: shared info for cygwin
3 Copyright 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009,
4 2010, 2011 Red Hat, Inc.
6 This file is part of Cygwin.
8 This software is a copyrighted work licensed under the terms of the
9 Cygwin license. Please consult the file "CYGWIN_LICENSE" for
17 NTSTATUS key_is_invalid;
22 reg_key (HKEY toplev, REGSAM access, ...);
23 reg_key (bool isHKLM, REGSAM access, ...);
25 void *operator new (size_t, void *p) {return p;}
26 void build_reg (HKEY key, REGSAM access, va_list av);
28 bool error () {return key == NULL;}
30 DWORD get_dword (PCWSTR, DWORD);
31 NTSTATUS get_string (PCWSTR, PWCHAR, size_t, PCWSTR);
33 NTSTATUS set_dword (PCWSTR, DWORD);
34 NTSTATUS set_string (PCWSTR, PCWSTR);
36 bool created () const {return _disposition & REG_CREATED_NEW_KEY;}
41 /* Evaluates path to the directory of the local user registry hive */
42 PWCHAR __stdcall get_registry_hive_path (PCWSTR name, PWCHAR path);
43 void __stdcall load_registry_hive (PCWSTR name);