@@ -69,6 +69,7 @@ pub type LPWCH = *mut WCHAR;
69
69
pub type LPWIN32_FIND_DATAW = * mut WIN32_FIND_DATAW ;
70
70
pub type LPWSADATA = * mut WSADATA ;
71
71
pub type LPWSAPROTOCOL_INFO = * mut WSAPROTOCOL_INFO ;
72
+ pub type LPSTR = * mut CHAR ;
72
73
pub type LPWSTR = * mut WCHAR ;
73
74
pub type LPFILETIME = * mut FILETIME ;
74
75
@@ -157,6 +158,7 @@ pub const WSAECONNREFUSED: c_int = 10061;
157
158
158
159
pub const MAX_PROTOCOL_CHAIN : DWORD = 7 ;
159
160
161
+ pub const PROCESS_QUERY_INFORMATION : DWORD = 0x0400 ;
160
162
pub const TOKEN_READ : DWORD = 0x20008 ;
161
163
pub const MAXIMUM_REPARSE_DATA_BUFFER_SIZE : usize = 16 * 1024 ;
162
164
pub const FSCTL_GET_REPARSE_POINT : DWORD = 0x900a8 ;
@@ -218,6 +220,10 @@ pub const CREATE_NEW_PROCESS_GROUP: DWORD = 0x00000200;
218
220
pub const CREATE_UNICODE_ENVIRONMENT : DWORD = 0x00000400 ;
219
221
pub const STARTF_USESTDHANDLES : DWORD = 0x00000100 ;
220
222
223
+ pub const CP_ACP : UINT = 0 ;
224
+
225
+ pub const WC_NO_BEST_FIT_CHARS : DWORD = 0x00000400 ;
226
+
221
227
pub const AF_INET : c_int = 2 ;
222
228
pub const AF_INET6 : c_int = 23 ;
223
229
pub const SD_BOTH : c_int = 2 ;
@@ -888,6 +894,9 @@ extern "system" {
888
894
pNumArgs : * mut c_int ) -> * mut * mut u16 ;
889
895
pub fn GetTempPathW ( nBufferLength : DWORD ,
890
896
lpBuffer : LPCWSTR ) -> DWORD ;
897
+ pub fn OpenProcess ( dwDesiredAccess : DWORD ,
898
+ bInheritHandle : BOOL ,
899
+ dwProcessId : DWORD ) -> HANDLE ;
891
900
pub fn OpenProcessToken ( ProcessHandle : HANDLE ,
892
901
DesiredAccess : DWORD ,
893
902
TokenHandle : * mut HANDLE ) -> BOOL ;
@@ -973,6 +982,14 @@ extern "system" {
973
982
pub fn DeleteFileW ( lpPathName : LPCWSTR ) -> BOOL ;
974
983
pub fn GetCurrentDirectoryW ( nBufferLength : DWORD , lpBuffer : LPWSTR ) -> DWORD ;
975
984
pub fn SetCurrentDirectoryW ( lpPathName : LPCWSTR ) -> BOOL ;
985
+ pub fn WideCharToMultiByte ( CodePage : UINT ,
986
+ dwFlags : DWORD ,
987
+ lpWideCharStr : LPCWSTR ,
988
+ cchWideChar : c_int ,
989
+ lpMultiByteStr : LPSTR ,
990
+ cbMultiByte : c_int ,
991
+ lpDefaultChar : LPCSTR ,
992
+ lpUsedDefaultChar : LPBOOL ) -> c_int ;
976
993
977
994
pub fn closesocket ( socket : SOCKET ) -> c_int ;
978
995
pub fn recv ( socket : SOCKET , buf : * mut c_void , len : c_int ,
@@ -1136,6 +1153,12 @@ compat_fn! {
1136
1153
_dwFlags: DWORD ) -> DWORD {
1137
1154
SetLastError ( ERROR_CALL_NOT_IMPLEMENTED as DWORD ) ; 0
1138
1155
}
1156
+ pub fn QueryFullProcessImageNameW ( _hProcess: HANDLE ,
1157
+ _dwFlags: DWORD ,
1158
+ _lpExeName: LPWSTR ,
1159
+ _lpdwSize: LPDWORD ) -> BOOL {
1160
+ SetLastError ( ERROR_CALL_NOT_IMPLEMENTED as DWORD ) ; 0
1161
+ }
1139
1162
pub fn SetThreadStackGuarantee ( _size: * mut c_ulong) -> BOOL {
1140
1163
SetLastError ( ERROR_CALL_NOT_IMPLEMENTED as DWORD ) ; 0
1141
1164
}
0 commit comments